Signed/unsigned comparisons part 1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



While compiling the tests in MSDev, I came across some signed/unsigned
comparisons. They are not detected with the default CFLAGS in the Unix
makefiles (to do that, we need either -Wsign-compare, or -W which
enables even more warnings).

This patch is the first part; the rest will go to tomorrow.

Changelog:
Fix signed/unsigned comparison.

Vincent
Index: wine/dlls/winmm/tests/wave.c
===================================================================
RCS file: /home/wine/wine/dlls/winmm/tests/wave.c,v
retrieving revision 1.1
diff -u -r1.1 wave.c
--- wine/dlls/winmm/tests/wave.c	4 Nov 2002 23:47:49 -0000	1.1
+++ wine/dlls/winmm/tests/wave.c	30 Nov 2002 07:12:10 -0000
@@ -104,7 +104,7 @@
             if (success) {
                 ok(format.nChannels==win_formats[f][3] &&
                    format.wBitsPerSample==win_formats[f][2] &&
-                   format.nSamplesPerSec==win_formats[f][1],
+                   format.nSamplesPerSec==(DWORD)win_formats[f][1],
                    "got the wrong format: %ldx%2dx%d instead of %dx%2dx%d\n",
                    format.nSamplesPerSec, format.wBitsPerSample,
                    format.nChannels, win_formats[f][1], win_formats[f][2],
@@ -120,7 +120,7 @@
             if (success) {
                 ok(format.nChannels==win_formats[f][3] &&
                    format.wBitsPerSample==win_formats[f][2] &&
-                   format.nSamplesPerSec==win_formats[f][1],
+                   format.nSamplesPerSec==(DWORD)win_formats[f][1],
                    "got the wrong format: %ldx%2dx%d instead of %dx%2dx%d\n",
                    format.nSamplesPerSec, format.wBitsPerSample,
                    format.nChannels, win_formats[f][1], win_formats[f][2],

[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux