kernel32/tests: Don't forget to delete a temporary file.

This commit is contained in:
Dmitry Timoshkov 2014-01-21 17:51:27 +09:00 committed by Alexandre Julliard
parent 9703bee560
commit 294adeec4f
1 changed files with 3 additions and 0 deletions

View File

@ -3843,6 +3843,7 @@ static void test_SetFileValidData(void)
{ {
win_skip("cannot enable SE_MANAGE_VOLUME_NAME privilege\n"); win_skip("cannot enable SE_MANAGE_VOLUME_NAME privilege\n");
CloseHandle(token); CloseHandle(token);
DeleteFileA(filename);
return; return;
} }
handle = CreateFileA(filename, GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL); handle = CreateFileA(filename, GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL);
@ -3906,7 +3907,9 @@ static void test_SetFileValidData(void)
privs.Privileges[0].Attributes = 0; privs.Privileges[0].Attributes = 0;
AdjustTokenPrivileges(token, FALSE, &privs, sizeof(privs), NULL, NULL); AdjustTokenPrivileges(token, FALSE, &privs, sizeof(privs), NULL, NULL);
CloseHandle(token); CloseHandle(token);
CloseHandle(handle);
DeleteFileA(filename); DeleteFileA(filename);
} }