- ExAllocatePoolWithTag is deprecated in Windows 10 2004 and replaced with
ExAllocatePool2. Use ExAllocatePoolUninitialized to maintain support for
earlier versions of Windows.
Signed-off-by: Owen Smith <owen.smith@citrix.com>
Split up original patch.
Signed-off-by: Paul Durrant <paul@xen.org>
__analysis_assume(PoolType == NonPagedPool ||
PoolType == PagedPool);
+#if (_MSC_VER >= 1928) // VS 16.9 (EWDK 20344 or later)
+ Buffer = ExAllocatePoolUninitialized(PoolType, NumberOfBytes, Tag);
+#else
#pragma warning(suppress:28160) // annotation error
Buffer = ExAllocatePoolWithTag(PoolType, NumberOfBytes, Tag);
+#endif
if (Buffer == NULL)
return NULL;