PR#331: for Visual Studio, use a snprintf/vsnprintf wrapper that ensures the string is terminated.

This commit is contained in:
Eric Haszlakiewicz
2017-08-25 01:15:39 -04:00
parent 256ebcd827
commit 81f6edbfd5
6 changed files with 41 additions and 18 deletions

View File

@@ -48,12 +48,7 @@
# define open _open
#endif
#if !defined(HAVE_SNPRINTF) && defined(_MSC_VER)
/* MSC has the version as _snprintf */
# define snprintf _snprintf
#elif !defined(HAVE_SNPRINTF)
# error You do not have snprintf on your system.
#endif /* HAVE_SNPRINTF */
#include "snprintf_compat.h"
#include "debug.h"
#include "printbuf.h"