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
59a2686a
Commit
59a2686a
authored
May 16, 2007
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
May 16, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Add a test for LoadLibraryEx(LOAD_LIBRARY_AS_DATAFILE).
parent
e2d94ec0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
1 deletion
+28
-1
loader.c
dlls/kernel32/tests/loader.c
+28
-1
No files found.
dlls/kernel32/tests/loader.c
View file @
59a2686a
...
...
@@ -231,7 +231,8 @@ START_TEST(loader)
static
const
char
section_data
[
0x10
]
=
"section data"
;
int
i
;
DWORD
dummy
,
file_size
,
file_align
;
HANDLE
hfile
,
hlib
;
HANDLE
hfile
;
HMODULE
hlib
,
hlib_as_data_file
;
SYSTEM_INFO
si
;
char
temp_path
[
MAX_PATH
];
char
dll_name
[
MAX_PATH
];
...
...
@@ -421,7 +422,33 @@ START_TEST(loader)
}
SetLastError
(
0xdeadbeef
);
hlib_as_data_file
=
LoadLibraryEx
(
dll_name
,
0
,
LOAD_LIBRARY_AS_DATAFILE
);
ok
(
hlib_as_data_file
!=
0
,
"LoadLibraryEx error %u
\n
"
,
GetLastError
());
todo_wine
ok
(
hlib_as_data_file
==
hlib
,
"hlib_as_file and hlib are different
\n
"
);
SetLastError
(
0xdeadbeef
);
ok
(
FreeLibrary
(
hlib
),
"FreeLibrary error %d
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
hlib
=
GetModuleHandle
(
dll_name
);
todo_wine
ok
(
hlib
!=
0
,
"GetModuleHandle error %u
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
ok
(
FreeLibrary
(
hlib_as_data_file
),
"FreeLibrary error %d
\n
"
,
GetLastError
());
hlib
=
GetModuleHandle
(
dll_name
);
ok
(
!
hlib
,
"GetModuleHandle should fail
\n
"
);
SetLastError
(
0xdeadbeef
);
hlib_as_data_file
=
LoadLibraryEx
(
dll_name
,
0
,
LOAD_LIBRARY_AS_DATAFILE
);
ok
(
hlib_as_data_file
!=
0
,
"LoadLibraryEx error %u
\n
"
,
GetLastError
());
ok
((
ULONG_PTR
)
hlib_as_data_file
&
1
,
"hlib_as_data_file is even
\n
"
);
hlib
=
GetModuleHandle
(
dll_name
);
ok
(
!
hlib
,
"GetModuleHandle should fail
\n
"
);
SetLastError
(
0xdeadbeef
);
ok
(
FreeLibrary
(
hlib_as_data_file
),
"FreeLibrary error %d
\n
"
,
GetLastError
());
}
else
{
/* LoadLibrary is expected to fail */
...
...
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