From c399c80a09a393d38368a44ef04753e9f62350f0 Mon Sep 17 00:00:00 2001 From: fanquake Date: Fri, 20 Jan 2023 17:09:24 +0000 Subject: [PATCH] cleanse: Use SecureZeroMemory for mingw-w64 (release) builds --- src/support/cleanse.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/support/cleanse.cpp b/src/support/cleanse.cpp index a8ddcd793f..4e370f1516 100644 --- a/src/support/cleanse.cpp +++ b/src/support/cleanse.cpp @@ -7,14 +7,14 @@ #include -#if defined(_MSC_VER) -#include // For SecureZeroMemory. +#if defined(WIN32) +#include #endif void memory_cleanse(void *ptr, size_t len) { -#if defined(_MSC_VER) - /* SecureZeroMemory is guaranteed not to be optimized out by MSVC. */ +#if defined(WIN32) + /* SecureZeroMemory is guaranteed not to be optimized out. */ SecureZeroMemory(ptr, len); #else std::memset(ptr, 0, len);