Make snprintf/vsnprintf more compatible with the C standard on MSVC.

git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3361 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
Meep-Eep
2009-11-28 18:00:46 +00:00
parent 441b7d9cdf
commit 1c6b9baa73
3 changed files with 67 additions and 8 deletions
+5 -4
View File
@@ -140,11 +140,12 @@ typedef unsigned short mode_t;
# include <alloca.h>
#endif
// Printf
// String formatting
#ifdef _MSC_VER
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#endif
// Defined in port.c
int snprintf(char *str, size_t size, const char *format, ...);
int vsnprintf(char *str, size_t size, const char *format, va_list args);
#endif /* _MSC_VER */
// setenv()
#ifndef HAVE_SETENV