kernel32/tests: Fix some test failures on Win9x and WinME.

This commit is contained in:
Paul Vriens 2009-01-31 15:23:33 +01:00 committed by Alexandre Julliard
parent 2bac661c2f
commit a8c24d343c
1 changed files with 4 additions and 1 deletions

View File

@ -377,8 +377,11 @@ static void test_profile_existing(void)
ok(INVALID_HANDLE_VALUE != h, "%d: CreateFile failed\n",i);
SetLastError(0xdeadbeef);
ret = GetPrivateProfileStringA(SECTION, KEY, NULL, buffer, MAX_PATH, testfile2);
/* Win9x and WinME returns 0 for all cases except the first one */
if (!pe[i].read_error)
ok( ret, "%d: GetPrivateProfileString failed with error %u\n", i, GetLastError() );
ok( ret ||
broken(!ret && GetLastError() == 0xdeadbeef), /* Win9x, WinME */
"%d: GetPrivateProfileString failed with error %u\n", i, GetLastError() );
else
ok( !ret, "%d: GetPrivateProfileString succeeded\n", i );
CloseHandle(h);