Fix GC_VSNPRINTF in cordprnt for DJGPP and MS VC for WinCE
authorIvan Maidanski <ivmai@mail.ru>
Fri, 7 Sep 2018 18:21:01 +0000 (21:21 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Fri, 7 Sep 2018 18:21:01 +0000 (21:21 +0300)
(fix of commit c10a1d900)

GC-internal DJGPP and MSWINCE macros are not available in cord.

* cord/cordprnt.c (GC_VSNPRINTF): Test __DJGPP__ instead of DJGPP macro.
* cord/cordprnt.c [_MSC_VER] (GC_VSNPRINTF): Test _WIN32_WCE instead
of MSWINCE macro.

cord/cordprnt.c

index 2dd5691..d9d9f53 100644 (file)
@@ -174,11 +174,11 @@ static int extract_conv_spec(CORD_pos source, char *buf,
     return(result);
 }
 
-#if defined(DJGPP) || defined(__STRICT_ANSI__)
+#if defined(__DJGPP__) || defined(__STRICT_ANSI__)
   /* vsnprintf is missing in DJGPP (v2.0.3) */
 # define GC_VSNPRINTF(buf, bufsz, format, args) vsprintf(buf, format, args)
 #elif defined(_MSC_VER)
-# ifdef MSWINCE
+# if defined(_WIN32_WCE)
     /* _vsnprintf is deprecated in WinCE */
 #   define GC_VSNPRINTF StringCchVPrintfA
 # else