<URL: http://bugs.freeciv.org/Ticket/Display.html?id=40057 >

mystrerror is included in support.c.  Two places don't use this but 
access strerror directly.  This patch fixes it (for 2.1).

-jason

Index: client/gui-sdl/gui_iconv.c
===================================================================
--- client/gui-sdl/gui_iconv.c	(revision 14336)
+++ client/gui-sdl/gui_iconv.c	(working copy)
@@ -208,7 +208,7 @@
       size_t Res =
 	  iconv(cd, (ICONV_CONST char **) &pInptr, &Insize, &pOutptr, &Outsize);
       if (Res == (size_t) (-1)) {
-        freelog(LOG_ERROR, "iconv() error: %s", strerror(errno));        
+        freelog(LOG_ERROR, "iconv() error: %s", mystrerror(errno));        
 	if (errno == EINVAL) {
 	  break;
 	} else {
Index: client/gui-mui/gui_main.c
===================================================================
--- client/gui-mui/gui_main.c	(revision 14336)
+++ client/gui-mui/gui_main.c	(working copy)
@@ -1085,7 +1085,7 @@
 	}
 	else if (sel < 0)
 	{
-	  printf("%s\n", strerror(errno));
+	  printf("%s\n", mystrerror(errno));
 	  break;
 	}
       }
_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to