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
4b2ba3e1
Commit
4b2ba3e1
authored
Mar 12, 2007
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Mar 12, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Make the error test pass under XP.
parent
540d8186
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
16 deletions
+16
-16
error.c
dlls/ntdll/tests/error.c
+16
-16
No files found.
dlls/ntdll/tests/error.c
View file @
4b2ba3e1
...
@@ -46,7 +46,7 @@
...
@@ -46,7 +46,7 @@
* (of course older Windows platforms will fail to pass the strict mode)
* (of course older Windows platforms will fail to pass the strict mode)
*/
*/
static
ULONG
(
WINAPI
*
statustodose
rror
)(
NTSTATUS
Status
);
static
ULONG
(
WINAPI
*
pRtlNtStatusToDosE
rror
)(
NTSTATUS
Status
);
static
int
strict
;
static
int
strict
;
static
int
prepare_test
(
void
)
static
int
prepare_test
(
void
)
...
@@ -56,8 +56,8 @@ static int prepare_test(void)
...
@@ -56,8 +56,8 @@ static int prepare_test(void)
char
**
argv
;
char
**
argv
;
ntdll
=
LoadLibraryA
(
"ntdll.dll"
);
ntdll
=
LoadLibraryA
(
"ntdll.dll"
);
statustodose
rror
=
(
void
*
)
GetProcAddress
(
ntdll
,
"RtlNtStatusToDosError"
);
pRtlNtStatusToDosE
rror
=
(
void
*
)
GetProcAddress
(
ntdll
,
"RtlNtStatusToDosError"
);
if
(
!
statustodose
rror
)
if
(
!
pRtlNtStatusToDosE
rror
)
return
0
;
return
0
;
argc
=
winetest_get_mainargs
(
&
argv
);
argc
=
winetest_get_mainargs
(
&
argv
);
...
@@ -69,9 +69,9 @@ static void cmp_call(NTSTATUS win_nt, ULONG win32, const char* message)
...
@@ -69,9 +69,9 @@ static void cmp_call(NTSTATUS win_nt, ULONG win32, const char* message)
{
{
ULONG
err
;
ULONG
err
;
err
=
statustodose
rror
(
win_nt
);
err
=
pRtlNtStatusToDosE
rror
(
win_nt
);
ok
(
err
==
win32
,
ok
(
err
==
win32
,
"%s (%x): got %
d, expected %d
\n
"
,
"%s (%x): got %
u, expected %u
\n
"
,
message
,
win_nt
,
err
,
win32
);
message
,
win_nt
,
err
,
win32
);
}
}
...
@@ -79,10 +79,10 @@ static void cmp_call2(NTSTATUS win_nt, ULONG win32, const char* message)
...
@@ -79,10 +79,10 @@ static void cmp_call2(NTSTATUS win_nt, ULONG win32, const char* message)
{
{
ULONG
err
;
ULONG
err
;
err
=
statustodose
rror
(
win_nt
);
err
=
pRtlNtStatusToDosE
rror
(
win_nt
);
ok
(
err
==
win32
||
ok
(
err
==
win32
||
(
!
strict
&&
err
==
ERROR_MR_MID_NOT_FOUND
),
(
!
strict
&&
err
==
ERROR_MR_MID_NOT_FOUND
),
"%s (%x): got %
d, expected %d
(or MID_NOT_FOUND)
\n
"
,
"%s (%x): got %
u, expected %u
(or MID_NOT_FOUND)
\n
"
,
message
,
win_nt
,
err
,
win32
);
message
,
win_nt
,
err
,
win32
);
}
}
...
@@ -90,9 +90,9 @@ static void cmp_call3(NTSTATUS win_nt, ULONG win32_1, ULONG win32_2, const char*
...
@@ -90,9 +90,9 @@ static void cmp_call3(NTSTATUS win_nt, ULONG win32_1, ULONG win32_2, const char*
{
{
ULONG
err
;
ULONG
err
;
err
=
statustodose
rror
(
win_nt
);
err
=
pRtlNtStatusToDosE
rror
(
win_nt
);
ok
(
err
==
win32_1
||
(
!
strict
&&
err
==
win32_2
),
ok
(
err
==
win32_1
||
(
!
strict
&&
err
==
win32_2
),
"%s (%x): got %
d, expected %d or %d
\n
"
,
"%s (%x): got %
u, expected %u or %u
\n
"
,
message
,
win_nt
,
err
,
win32_1
,
win32_2
);
message
,
win_nt
,
err
,
win32_1
,
win32_2
);
}
}
...
@@ -100,10 +100,10 @@ static void cmp_call4(NTSTATUS win_nt, ULONG win32_1, ULONG win32_2, const char*
...
@@ -100,10 +100,10 @@ static void cmp_call4(NTSTATUS win_nt, ULONG win32_1, ULONG win32_2, const char*
{
{
ULONG
err
;
ULONG
err
;
err
=
statustodose
rror
(
win_nt
);
err
=
pRtlNtStatusToDosE
rror
(
win_nt
);
ok
(
err
==
win32_1
||
ok
(
err
==
win32_1
||
(
!
strict
&&
(
err
==
win32_2
||
err
==
ERROR_MR_MID_NOT_FOUND
)),
(
!
strict
&&
(
err
==
win32_2
||
err
==
ERROR_MR_MID_NOT_FOUND
)),
"%s (%x): got %
d, expected %d or %d
\n
"
,
"%s (%x): got %
u, expected %u or %u
\n
"
,
message
,
win_nt
,
err
,
win32_1
,
win32_2
);
message
,
win_nt
,
err
,
win32_1
,
win32_2
);
}
}
...
@@ -245,11 +245,11 @@ static void run_error_tests(void)
...
@@ -245,11 +245,11 @@ static void run_error_tests(void)
cmp2
(
STATUS_PKINIT_FAILURE
,
ERROR_PKINIT_FAILURE
);
cmp2
(
STATUS_PKINIT_FAILURE
,
ERROR_PKINIT_FAILURE
);
cmp2
(
STATUS_SMARTCARD_SUBSYSTEM_FAILURE
,
ERROR_SMARTCARD_SUBSYSTEM_FAILURE
);
cmp2
(
STATUS_SMARTCARD_SUBSYSTEM_FAILURE
,
ERROR_SMARTCARD_SUBSYSTEM_FAILURE
);
cmp2
(
STATUS_DOWNGRADE_DETECTED
,
ERROR_DOWNGRADE_DETECTED
);
cmp2
(
STATUS_DOWNGRADE_DETECTED
,
ERROR_DOWNGRADE_DETECTED
);
cmp
2
(
STATUS_SMARTCARD_CERT_REVOKED
,
SEC_E_SMARTCARD_CERT_REVOKED
);
cmp
3
(
STATUS_SMARTCARD_CERT_REVOKED
,
SEC_E_SMARTCARD_CERT_REVOKED
,
1266
);
/* FIXME: real name? */
cmp
2
(
STATUS_ISSUING_CA_UNTRUSTED
,
SEC_E_ISSUING_CA_UNTRUSTED
);
cmp
3
(
STATUS_ISSUING_CA_UNTRUSTED
,
SEC_E_ISSUING_CA_UNTRUSTED
,
1267
);
/* FIXME: real name? */
cmp
2
(
STATUS_REVOCATION_OFFLINE_C
,
SEC_E_REVOCATION_OFFLINE_C
);
cmp
3
(
STATUS_REVOCATION_OFFLINE_C
,
SEC_E_REVOCATION_OFFLINE_C
,
1268
);
/* FIXME: real name? */
cmp
2
(
STATUS_PKINIT_CLIENT_FAILURE
,
SEC_E_PKINIT_CLIENT_FAILURE
);
cmp
3
(
STATUS_PKINIT_CLIENT_FAILURE
,
SEC_E_PKINIT_CLIENT_FAILURE
,
1269
);
/* FIXME: real name? */
cmp
2
(
STATUS_SMARTCARD_CERT_EXPIRED
,
SEC_E_SMARTCARD_CERT_EXPIRED
);
cmp
3
(
STATUS_SMARTCARD_CERT_EXPIRED
,
SEC_E_SMARTCARD_CERT_EXPIRED
,
1270
);
/* FIXME: real name? */
cmp2
(
STATUS_NO_KERB_KEY
,
SEC_E_NO_KERB_KEY
);
cmp2
(
STATUS_NO_KERB_KEY
,
SEC_E_NO_KERB_KEY
);
cmp2
(
STATUS_CURRENT_DOMAIN_NOT_ALLOWED
,
ERROR_CURRENT_DOMAIN_NOT_ALLOWED
);
cmp2
(
STATUS_CURRENT_DOMAIN_NOT_ALLOWED
,
ERROR_CURRENT_DOMAIN_NOT_ALLOWED
);
cmp2
(
STATUS_SMARTCARD_WRONG_PIN
,
SCARD_W_WRONG_CHV
);
cmp2
(
STATUS_SMARTCARD_WRONG_PIN
,
SCARD_W_WRONG_CHV
);
...
...
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