msvc: Move ssize_t typedef to MSVC-only

This is a MSVC-only issue. All other compilers we support work properly.
This commit is contained in:
Vicent Martí 2012-01-26 17:53:46 -08:00
parent 99a07f0f4d
commit a53420e4b0
2 changed files with 3 additions and 4 deletions

View File

@ -33,10 +33,6 @@
# define snprintf _snprintf # define snprintf _snprintf
#ifndef _SSIZE_T_DEFINED
typedef SSIZE_T ssize_t;
#endif
#else #else
# include <unistd.h> # include <unistd.h>

View File

@ -33,6 +33,9 @@
# define strcasecmp _stricmp # define strcasecmp _stricmp
# define strncasecmp _strnicmp # define strncasecmp _strnicmp
/* MSVC doesn't define ssize_t at all */
typedef SSIZE_T ssize_t;
#endif #endif
#endif /* INCLUDE_msvc_compat__ */ #endif /* INCLUDE_msvc_compat__ */