From 733e760638dbef96484b097a9a92b261503e2c74 Mon Sep 17 00:00:00 2001 From: Bart House Date: Sun, 14 Jul 2019 21:18:03 -0700 Subject: [PATCH] Revert "Remove the remapping of snprintf to _snprintf when compiling with MSC." This reverts commit 9801635f56804a195c2b1f5c6bec0e239c9c4935. --- include/ntconf.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/include/ntconf.h b/include/ntconf.h index 9d79006f0..994615c2d 100644 --- a/include/ntconf.h +++ b/include/ntconf.h @@ -146,6 +146,14 @@ extern void NDECL(getlock); #define strncmpi(a, b, c) strnicmp(a, b, c) #endif +#ifdef _MSC_VER +/* Visual Studio defines this in their own headers, which we don't use */ +#ifndef snprintf +#define snprintf _snprintf +#pragma warning( \ + disable : 4996) /* deprecation warning suggesting snprintf_s */ +#endif +#endif #include #include