Update memory.cpp

This commit is contained in:
Maurice Heumann 2022-08-22 10:23:21 +02:00 committed by GitHub
parent 620de17a01
commit 2fad5d0684
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -102,7 +102,10 @@ namespace memory
void* allocate_non_paged_memory(const size_t size) void* allocate_non_paged_memory(const size_t size)
{ {
void* memory = ExAllocatePool2(NonPagedPool, size, 'MOMO'); #pragma warning(push)
#pragma warning(disable: 4996)
void* memory = ExAllocatePoolWithTag(NonPagedPool, size, 'MOMO');
#pragma warning(pop)
if (memory) if (memory)
{ {
RtlSecureZeroMemory(memory, size); RtlSecureZeroMemory(memory, size);