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
936d663b
Commit
936d663b
authored
May 12, 1999
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed bug I introduced in relay debugging.
parent
3b3ff2bb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
16 deletions
+17
-16
builtin32.c
relay32/builtin32.c
+17
-16
No files found.
relay32/builtin32.c
View file @
936d663b
...
...
@@ -223,6 +223,21 @@ static HMODULE BUILTIN32_DoLoadImage( BUILTIN32_DLL *dll )
if
(
dll
->
descr
->
dllentrypoint
)
nt
->
OptionalHeader
.
AddressOfEntryPoint
=
(
DWORD
)
dll
->
descr
->
dllentrypoint
-
(
DWORD
)
addr
;
/* Build the code section */
strcpy
(
sec
->
Name
,
".code"
);
sec
->
SizeOfRawData
=
0
;
#ifdef __i386__
if
(
WARN_ON
(
relay
)
||
TRACE_ON
(
relay
))
sec
->
SizeOfRawData
+=
dll
->
descr
->
nb_funcs
*
sizeof
(
DEBUG_ENTRY_POINT
);
#endif
sec
->
Misc
.
VirtualSize
=
sec
->
SizeOfRawData
;
sec
->
VirtualAddress
=
(
BYTE
*
)
debug
-
addr
;
sec
->
PointerToRawData
=
(
BYTE
*
)
debug
-
addr
;
sec
->
Characteristics
=
(
IMAGE_SCN_CNT_INITIALIZED_DATA
|
IMAGE_SCN_MEM_EXECUTE
|
IMAGE_SCN_MEM_READ
);
sec
++
;
/* Build the import directory */
if
(
dll
->
descr
->
nb_imports
)
...
...
@@ -272,6 +287,7 @@ static HMODULE BUILTIN32_DoLoadImage( BUILTIN32_DLL *dll )
sec
->
Characteristics
=
(
IMAGE_SCN_CNT_INITIALIZED_DATA
|
IMAGE_SCN_MEM_EXECUTE
|
IMAGE_SCN_MEM_READ
|
IMAGE_SCN_MEM_WRITE
);
sec
++
;
/* Build the resource directory */
if
(
dll
->
rsc
)
...
...
@@ -304,21 +320,6 @@ static HMODULE BUILTIN32_DoLoadImage( BUILTIN32_DLL *dll )
}
}
/* Build the code section */
sec
++
;
strcpy
(
sec
->
Name
,
".code"
);
sec
->
SizeOfRawData
=
0
;
#ifdef __i386__
if
(
WARN_ON
(
relay
)
||
TRACE_ON
(
relay
))
sec
->
SizeOfRawData
+=
dll
->
descr
->
nb_funcs
*
sizeof
(
DEBUG_ENTRY_POINT
);
#endif
sec
->
Misc
.
VirtualSize
=
sec
->
SizeOfRawData
;
sec
->
VirtualAddress
=
(
BYTE
*
)
debug
-
addr
;
sec
->
PointerToRawData
=
(
BYTE
*
)
debug
-
addr
;
sec
->
Characteristics
=
(
IMAGE_SCN_CNT_INITIALIZED_DATA
|
IMAGE_SCN_MEM_EXECUTE
|
IMAGE_SCN_MEM_READ
);
/* Build the exports section data */
exp
->
Name
=
((
BYTE
*
)
dll
->
descr
->
name
)
-
addr
;
/*??*/
...
...
@@ -530,7 +531,7 @@ ENTRYPOINT32 BUILTIN32_GetEntryPoint( char *buffer, void *relay,
{
IMAGE_SECTION_HEADER
*
sec
=
PE_SECTIONS
(
hModule
);
DEBUG_ENTRY_POINT
*
debug
=
(
DEBUG_ENTRY_POINT
*
)((
DWORD
)
hModule
+
sec
[
1
].
VirtualAddress
);
(
DEBUG_ENTRY_POINT
*
)((
DWORD
)
hModule
+
sec
[
0
].
VirtualAddress
);
DEBUG_ENTRY_POINT
*
func
=
(
DEBUG_ENTRY_POINT
*
)
relay
;
if
(
debug
<=
func
&&
func
<
debug
+
dll
->
descr
->
nb_funcs
)
...
...
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