user32: fix a compiler warning on mingw

Austin English austinenglish at gmail.com
Thu Jul 1 10:20:33 CDT 2010


i586-mingw32msvc-gcc -c -I../../../wineclean/dlls/user32 -I.
-I../../../wineclean/include -I../../include  -D__WINESRC__ -D_USER32_
-D_WINABLE_ -D_REENTRANT -Wall -pipe -fno-strength-reduce
-fno-strict-aliasing -Wdeclaration-after-statement -Wstrict-prototypes
-Wtype-limits -Wwrite-strings -Wpointer-arith  -g -O2 -D_WIN32  -o
sysparams.o ../../../wineclean/dlls/user32/sysparams.c
../../../wineclean/dlls/user32/sysparams.c: In function ‘SYSPARAMS_Init’:
../../../wineclean/dlls/user32/sysparams.c:946: warning: unused
variable ‘iNumColors’


-- 
-Austin
-------------- next part --------------
diff --git a/dlls/user32/sysparams.c b/dlls/user32/sysparams.c
index e6d2386..1eb78cb 100644
--- a/dlls/user32/sysparams.c
+++ b/dlls/user32/sysparams.c
@@ -943,7 +943,8 @@ void SYSPARAMS_Init(void)
         /* last chance, take the default */
         if (!bOk)
         {
-            int iNumColors = sscanf( DefSysColors[i*2+1], " %d %d %d", &r, &g, &b );
+            int iNumColors;
+            iNumColors = sscanf( DefSysColors[i*2+1], " %d %d %d", &r, &g, &b );
             assert (iNumColors==3);
         }


More information about the wine-patches mailing list