diff mbox

[ovs-dev,02/40] datapath-windows: Use non-executable memory when allocating memory

Message ID 20170714044033.15196-3-aserdean@cloudbasesolutions.com
State Accepted
Headers show

Commit Message

Alin Serdean July 14, 2017, 4:40 a.m. UTC
Use non-executable memory when using ExAllocatePoolWithTagPriority.

Found using WDK 10 static code analysis.

Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
---
 datapath-windows/ovsext/Util.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/datapath-windows/ovsext/Util.c b/datapath-windows/ovsext/Util.c
index a1ce0e6..3c9b052 100644
--- a/datapath-windows/ovsext/Util.c
+++ b/datapath-windows/ovsext/Util.c
@@ -60,7 +60,7 @@  OvsAllocateAlignedMemory(size_t size, UINT16 align)
          * XXX: NdisAllocateMemory*() functions don't talk anything about
          * alignment. Hence using ExAllocatePool*();
          */
-        return (VOID *)ExAllocatePoolWithTagPriority(NonPagedPool, size,
+        return (VOID *)ExAllocatePoolWithTagPriority(NonPagedPoolNx, size,
                                                      OVS_MEMORY_TAG,
                                                      NormalPoolPriority);
     }