setupapi: SetLastError to ERROR_SUCCESS on success.
This commit is contained in:
parent
672952d2b6
commit
405b96e979
|
@ -921,6 +921,7 @@ done:
|
||||||
MyFree( destW );
|
MyFree( destW );
|
||||||
HeapFree( GetProcessHeap(), 0, sourceW );
|
HeapFree( GetProcessHeap(), 0, sourceW );
|
||||||
HeapFree( GetProcessHeap(), 0, locationW );
|
HeapFree( GetProcessHeap(), 0, locationW );
|
||||||
|
if (ret) SetLastError(ERROR_SUCCESS);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -980,6 +981,7 @@ BOOL WINAPI SetupCopyOEMInfW( PCWSTR source, PCWSTR location,
|
||||||
|
|
||||||
if (component) *component = p + 1;
|
if (component) *component = p + 1;
|
||||||
if (required_size) *required_size = size;
|
if (required_size) *required_size = size;
|
||||||
|
if (ret) SetLastError(ERROR_SUCCESS);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
|
@ -243,11 +243,8 @@ static void test_SetupCopyOEMInf(void)
|
||||||
SetLastError(0xdeadbeef);
|
SetLastError(0xdeadbeef);
|
||||||
res = SetupCopyOEMInf(path, NULL, SPOST_NONE, SP_COPY_DELETESOURCE, NULL, 0, NULL, NULL);
|
res = SetupCopyOEMInf(path, NULL, SPOST_NONE, SP_COPY_DELETESOURCE, NULL, 0, NULL, NULL);
|
||||||
ok(res == TRUE, "Expected TRUE, got %d\n", res);
|
ok(res == TRUE, "Expected TRUE, got %d\n", res);
|
||||||
|
ok(GetLastError() == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", GetLastError());
|
||||||
ok(!file_exists(path), "Expected source inf to not exist\n");
|
ok(!file_exists(path), "Expected source inf to not exist\n");
|
||||||
todo_wine
|
|
||||||
{
|
|
||||||
ok(GetLastError() == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", GetLastError());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
START_TEST(misc)
|
START_TEST(misc)
|
||||||
|
|
Loading…
Reference in New Issue