[MPlayer-cvslog] r37360 - in trunk: configure gui/win32/skinload.c

ib subversion at mplayerhq.hu
Fri Jan 16 22:38:35 CET 2015


Author: ib
Date: Fri Jan 16 22:38:35 2015
New Revision: 37360

Log:
Replace stricmp by strcasecmp.

This is preferable to the approach in r37357.

(We have to define strcasecmp for Wine because there is only a prototype
for it with the msvcrt C library, but we are using the native glibc one.)

Modified:
   trunk/configure
   trunk/gui/win32/skinload.c

Modified: trunk/configure
==============================================================================
--- trunk/configure	Fri Jan 16 22:30:02 2015	(r37359)
+++ trunk/configure	Fri Jan 16 22:38:35 2015	(r37360)
@@ -1821,7 +1821,7 @@ if os2 ; then
 fi
 
 if wine ; then
-  extra_cflags="-fno-pic -UWIN32 -U_WIN32 -U__WIN32 -U__WIN32__ -DWINE_NOWINSOCK -Dstricmp=lstrcmpiA $extra_cflags"
+  extra_cflags="-fno-pic -UWIN32 -U_WIN32 -U__WIN32 -U__WIN32__ -DWINE_NOWINSOCK -Dstrcasecmp=lstrcmpiA $extra_cflags"
 fi
 
 if darwin && test "$cc_vendor" != "clang" ; then

Modified: trunk/gui/win32/skinload.c
==============================================================================
--- trunk/gui/win32/skinload.c	Fri Jan 16 22:30:02 2015	(r37359)
+++ trunk/gui/win32/skinload.c	Fri Jan 16 22:38:35 2015	(r37360)
@@ -39,12 +39,6 @@
 #include "gui/util/mem.h"
 #include "gui/util/bitmap.h"
 
-#ifndef stricmp
-#ifdef __CYGWIN__
-#define stricmp strcasecmp
-#endif
-#endif
-
 #define MAX_LINESIZE 256
 
 typedef struct
@@ -152,7 +146,7 @@ static image *pngRead(skin_t *skin, cons
     char *filename = NULL;
     FILE *fp;
 
-    if(!stricmp(fname, "NULL")) return 0;
+    if(!strcasecmp(fname, "NULL")) return 0;
 
     /* find filename in order file file.png */
     if(!(fp = fopen(fname, "rb")))


More information about the MPlayer-cvslog mailing list