version/tests: Replace some '#if 0's with 'if (0)'s.
Francois Gouget
fgouget at free.fr
Thu Dec 14 11:10:59 CST 2006
Fix the code so it compiles without warnings.
---
dlls/version/tests/info.c | 16 +++++++++-------
1 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/dlls/version/tests/info.c b/dlls/version/tests/info.c
index c71ecc6..5eafa49 100644
--- a/dlls/version/tests/info.c
+++ b/dlls/version/tests/info.c
@@ -199,17 +199,18 @@ static void test_info(void)
if (pVersionInfo == 0)
return;
-#if 0
+ if (0)
+ {
/* this test crashes on WinNT4
*/
boolret = GetFileVersionInfoA( "kernel32.dll", 0, retval, 0);
- ok (!boolret, "GetFileVersionInfoA should have failed: GetLastError = 0x%08lx\n", GetLastError());
+ ok (!boolret, "GetFileVersionInfoA should have failed: GetLastError = %d\n", GetLastError());
ok ((GetLastError() == ERROR_INVALID_DATA) || (GetLastError() == ERROR_BAD_PATHNAME) ||
(GetLastError() == NO_ERROR),
"Last error wrong! ERROR_INVALID_DATA/ERROR_BAD_PATHNAME (ME)/"
- "NO_ERROR (95) expected, got 0x%08lx\n",
+ "NO_ERROR (95) expected, got 0x%08x\n",
GetLastError());
-#endif
+ }
boolret = GetFileVersionInfoA( "kernel32.dll", 0, retval, pVersionInfo );
ok (boolret, "GetFileVersionInfoA failed: GetLastError = 0x%08x\n", GetLastError());
@@ -228,12 +229,13 @@ static void test_info(void)
trace("kernel32.dll version: %s\n", VersionString);
-#if 0
+ if (0)
+ {
/* this test crashes on WinNT4
*/
boolret = VerQueryValueA( pVersionInfo, "\\", (LPVOID *)&pFixedVersionInfo, 0);
- ok (boolret, "VerQueryValue failed: GetLastError = 0x%08lx\n", GetLastError());
-#endif
+ ok (boolret, "VerQueryValue failed: GetLastError = 0x%08x\n", GetLastError());
+ }
cleanup:
HeapFree( GetProcessHeap(), 0, pVersionInfo);
--
1.4.4.1
More information about the wine-patches
mailing list