Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
2df367a4
Commit
2df367a4
authored
Feb 15, 2018
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32/tests: Add some tests for CIL 32-bit image flags.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
50e53643
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
2 deletions
+30
-2
loader.c
dlls/kernel32/tests/loader.c
+28
-1
winnt.h
include/winnt.h
+2
-1
No files found.
dlls/kernel32/tests/loader.c
View file @
2df367a4
...
...
@@ -405,7 +405,8 @@ static BOOL query_image_section( int id, const char *dll_name, const IMAGE_NT_HE
todo_wine
ok
(
S
(
U
(
image
)).
ComPlusILOnly
||
broken
(
is_winxp
),
"%u: wrong ComPlusILOnly flags %02x
\n
"
,
id
,
U
(
image
).
ImageFlags
);
if
(
nt_header
->
OptionalHeader
.
Magic
==
IMAGE_NT_OPTIONAL_HDR32_MAGIC
)
if
(
nt_header
->
OptionalHeader
.
Magic
==
IMAGE_NT_OPTIONAL_HDR32_MAGIC
&&
!
(
cor_header
->
Flags
&
COMIMAGE_FLAGS_32BITREQUIRED
))
todo_wine
ok
(
S
(
U
(
image
)).
ComPlusNativeReady
||
broken
(
is_winxp
),
"%u: wrong ComPlusNativeReady flags %02x
\n
"
,
id
,
U
(
image
).
ImageFlags
);
...
...
@@ -1019,6 +1020,14 @@ static void test_Loader(void)
status
=
map_image_section
(
&
nt_header
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITREQUIRED
;
status
=
map_image_section
(
&
nt_header
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITPREFERRED
;
status
=
map_image_section
(
&
nt_header
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
0
;
status
=
map_image_section
(
&
nt_header
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
...
...
@@ -1122,6 +1131,16 @@ static void test_Loader(void)
ok
(
status
==
(
is_wow64
?
STATUS_SUCCESS
:
STATUS_INVALID_IMAGE_WIN_64
),
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITREQUIRED
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt64
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
(
is_wow64
?
STATUS_SUCCESS
:
STATUS_INVALID_IMAGE_WIN_64
),
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITPREFERRED
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt64
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
(
is_wow64
?
STATUS_SUCCESS
:
STATUS_INVALID_IMAGE_WIN_64
),
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
0
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt64
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
(
is_wow64
?
STATUS_SUCCESS
:
STATUS_INVALID_IMAGE_WIN_64
),
...
...
@@ -1218,6 +1237,14 @@ static void test_Loader(void)
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt32
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITREQUIRED
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt32
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
COMIMAGE_FLAGS_ILONLY
|
COMIMAGE_FLAGS_32BITPREFERRED
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt32
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
cor_header
.
Flags
=
0
;
status
=
map_image_section
(
(
IMAGE_NT_HEADERS
*
)
&
nt32
,
&
section
,
&
cor_header
,
__LINE__
);
ok
(
status
==
STATUS_SUCCESS
,
"NtCreateSection error %08x
\n
"
,
status
);
...
...
include/winnt.h
View file @
2df367a4
...
...
@@ -3621,10 +3621,11 @@ typedef enum ReplacesCorHdrNumericDefines
COMIMAGE_FLAGS_STRONGNAMESIGNED
=
0x00000008
,
COMIMAGE_FLAGS_NATIVE_ENTRYPOINT
=
0x00000010
,
COMIMAGE_FLAGS_TRACKDEBUGDATA
=
0x00010000
,
COMIMAGE_FLAGS_32BITPREFERRED
=
0x00020000
,
COR_VERSION_MAJOR_V2
=
2
,
COR_VERSION_MAJOR
=
COR_VERSION_MAJOR_V2
,
COR_VERSION_MINOR
=
0
,
COR_VERSION_MINOR
=
5
,
COR_DELETED_NAME_LENGTH
=
8
,
COR_VTABLEGAP_NAME_LENGTH
=
8
,
...
...
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