PR#331: for Visual Studio, use a snprintf/vsnprintf wrapper that ensures the string is terminated.
This commit is contained in:
1 parent
256ebcd827
commit
81f6edbfd5
6 files changed
+41
-18
No files matched your search
+1
-7
@@ -31,13 +31,7 @@
|
||||
#include "json_util.h"
|
||||
#include "math_compat.h"
|
||||
#include "strdup_compat.h"
|
||||
|
||||
#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"
|
||||
|
||||
// Don't define this. It's not thread-safe.
|
||||
/* #define REFCOUNT_DEBUG 1 */
|
||||
|
||||
Reference in new issue
Block a user