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
706c5400
Commit
706c5400
authored
Oct 26, 2021
by
Eric Pouech
Committed by
Alexandre Julliard
Oct 27, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp: Rewrite SymSetContext() on top of SymSetScopeFromAddr().
Signed-off-by:
Eric Pouech
<
eric.pouech@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
925182b0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
15 deletions
+8
-15
dbghelp.c
dlls/dbghelp/dbghelp.c
+8
-15
No files found.
dlls/dbghelp/dbghelp.c
View file @
706c5400
...
...
@@ -607,34 +607,27 @@ BOOL WINAPI SymSetContext(HANDLE hProcess, PIMAGEHLP_STACK_FRAME StackFrame,
PIMAGEHLP_CONTEXT
Context
)
{
struct
process
*
pcs
;
struct
module_pair
pair
;
struct
symt_ht
*
sym
;
BOOL
same
;
pair
.
pcs
=
pcs
=
process_find_by_handle
(
hProcess
);
if
(
!
pcs
)
return
FALSE
;
if
(
!
(
pcs
=
process_find_by_handle
(
hProcess
)))
return
FALSE
;
same
=
pcs
->
ctx_frame
.
ReturnOffset
==
StackFrame
->
ReturnOffset
&&
pcs
->
ctx_frame
.
FrameOffset
==
StackFrame
->
FrameOffset
&&
pcs
->
ctx_frame
.
StackOffset
==
StackFrame
->
StackOffset
;
pair
.
requested
=
module_find_by_addr
(
pair
.
pcs
,
StackFrame
->
InstructionOffset
,
DMT_UNKNOWN
);
if
(
!
module_get_debug
(
&
pair
))
return
FALSE
;
if
(
!
SymSetScopeFromAddr
(
hProcess
,
StackFrame
->
InstructionOffset
))
return
FALSE
;
if
((
sym
=
symt_find_nearest
(
pair
.
effective
,
StackFrame
->
InstructionOffset
))
==
NULL
)
return
FALSE
;
if
(
sym
->
symt
.
tag
!=
SymTagFunction
)
return
FALSE
;
pcs
->
localscope_pc
=
StackFrame
->
InstructionOffset
;
pcs
->
localscope_symt
=
&
sym
->
symt
;
if
(
pcs
->
ctx_frame
.
ReturnOffset
==
StackFrame
->
ReturnOffset
&&
pcs
->
ctx_frame
.
FrameOffset
==
StackFrame
->
FrameOffset
&&
pcs
->
ctx_frame
.
StackOffset
==
StackFrame
->
StackOffset
)
pcs
->
ctx_frame
=
*
StackFrame
;
if
(
same
)
{
TRACE
(
"Setting same frame {rtn=%I64x frm=%I64x stk=%I64x}
\n
"
,
pcs
->
ctx_frame
.
ReturnOffset
,
pcs
->
ctx_frame
.
FrameOffset
,
pcs
->
ctx_frame
.
StackOffset
);
pcs
->
ctx_frame
.
InstructionOffset
=
StackFrame
->
InstructionOffset
;
SetLastError
(
ERROR_SUCCESS
);
return
FALSE
;
}
pcs
->
ctx_frame
=
*
StackFrame
;
/* Context is not (no longer?) used */
return
TRUE
;
}
...
...
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