Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
d4c48db4
Commit
d4c48db4
authored
Jan 25, 2008
by
Reece H. Dunn
Committed by
Alexandre Julliard
Jan 25, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
advapi32: Fix some cred test failures on Vista and prevent it crashing.
parent
e3a5167f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
11 deletions
+14
-11
cred.c
dlls/advapi32/tests/cred.c
+14
-11
No files found.
dlls/advapi32/tests/cred.c
View file @
d4c48db4
...
...
@@ -50,8 +50,8 @@ static void test_CredReadA(void)
SetLastError
(
0xdeadbeef
);
ret
=
pCredReadA
(
TEST_TARGET_NAME
,
CRED_TYPE_GENERIC
,
0xdeadbeef
,
&
cred
);
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_FLAGS
,
"CredReadA should have failed with ERROR_INVALID_FLAGS instead of %d
\n
"
,
ok
(
!
ret
&&
(
GetLastError
()
==
ERROR_INVALID_FLAGS
||
GetLastError
()
==
ERROR_INVALID_PARAMETER
)
,
"CredReadA should have failed with ERROR_INVALID_FLAGS
or ERROR_INVALID_PARAMETER
instead of %d
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
...
...
@@ -95,8 +95,8 @@ static void test_CredWriteA(void)
SetLastError
(
0xdeadbeef
);
ret
=
pCredWriteA
(
&
new_cred
,
0
);
ok
(
!
ret
&&
GetLastError
()
==
ERROR_BAD_USERNAME
,
"CredWrite with username without domain should return ERROR_BAD_USERNAME not %d
\n
"
,
GetLastError
());
ok
(
!
ret
&&
(
GetLastError
()
==
ERROR_BAD_USERNAME
||
GetLastError
()
==
ERROR_NO_SUCH_LOGON_SESSION
/* Vista */
)
,
"CredWrite with username without domain should return ERROR_BAD_USERNAME
or ERROR_NO_SUCH_LOGON_SESSION
not %d
\n
"
,
GetLastError
());
new_cred
.
UserName
=
NULL
;
SetLastError
(
0xdeadbeef
);
...
...
@@ -118,8 +118,8 @@ static void test_CredDeleteA(void)
SetLastError
(
0xdeadbeef
);
ret
=
pCredDeleteA
(
TEST_TARGET_NAME
,
CRED_TYPE_GENERIC
,
0xdeadbeef
);
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_FLAGS
,
"CredDeleteA should have failed with ERROR_INVALID_FLAGS instead of %d
\n
"
,
ok
(
!
ret
&&
(
GetLastError
()
==
ERROR_INVALID_FLAGS
||
GetLastError
()
==
ERROR_INVALID_PARAMETER
/* Vista */
)
,
"CredDeleteA should have failed with ERROR_INVALID_FLAGS
or ERROR_INVALID_PARAMETER
instead of %d
\n
"
,
GetLastError
());
}
...
...
@@ -226,11 +226,14 @@ static void test_domain_password(void)
ret
=
pCredReadA
(
TEST_TARGET_NAME
,
CRED_TYPE_DOMAIN_PASSWORD
,
0
,
&
cred
);
ok
(
ret
,
"CredReadA failed with error %d
\n
"
,
GetLastError
());
todo_wine
ok
(
cred
->
CredentialBlobSize
==
0
,
"expected CredentialBlobSize of 0 but got %d
\n
"
,
cred
->
CredentialBlobSize
);
todo_wine
ok
(
!
cred
->
CredentialBlob
,
"expected NULL credentials but got %p
\n
"
,
cred
->
CredentialBlob
);
pCredFree
(
cred
);
if
(
ret
)
/* don't check the values of cred, if CredReadA failed. */
{
todo_wine
ok
(
cred
->
CredentialBlobSize
==
0
,
"expected CredentialBlobSize of 0 but got %d
\n
"
,
cred
->
CredentialBlobSize
);
todo_wine
ok
(
!
cred
->
CredentialBlob
,
"expected NULL credentials but got %p
\n
"
,
cred
->
CredentialBlob
);
pCredFree
(
cred
);
}
ret
=
pCredDeleteA
(
TEST_TARGET_NAME
,
CRED_TYPE_DOMAIN_PASSWORD
,
0
);
ok
(
ret
,
"CredDeleteA failed with error %d
\n
"
,
GetLastError
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment