Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alexey Alyaev
wine
Commits
9c18d92f
Commit
9c18d92f
authored
17 years ago
by
Alexandre Julliard
Browse files
Options
Downloads
Patches
Plain Diff
server: Detaching from a process needs to continue all the pending events.
parent
fc635fa8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
server/debugger.c
+12
-17
12 additions, 17 deletions
server/debugger.c
with
12 additions
and
17 deletions
server/debugger.c
+
12
−
17
View file @
9c18d92f
...
...
@@ -451,7 +451,7 @@ static int debugger_attach( struct process *process, struct thread *debugger )
/* detach a process from a debugger thread (and resume it ?) */
int
debugger_detach
(
struct
process
*
process
,
struct
thread
*
debugger
)
{
struct
debug_event
*
event
;
struct
debug_event
*
event
,
*
next
;
struct
debug_ctx
*
debug_ctx
;
if
(
!
process
->
debugger
||
process
->
debugger
!=
debugger
)
...
...
@@ -464,23 +464,18 @@ int debugger_detach( struct process *process, struct thread *debugger )
/* send continue indication for all events */
debug_ctx
=
debugger
->
debug_ctx
;
/* find the event in the queue
* FIXME: could loop on process' threads and look the debug_event field */
LIST_FOR_EACH_ENTRY
(
event
,
&
debug_ctx
->
event_queue
,
struct
debug_event
,
entry
)
/* free all events from this process */
LIST_FOR_EACH_ENTRY_SAFE
(
event
,
next
,
&
debug_ctx
->
event_queue
,
struct
debug_event
,
entry
)
{
if
(
event
->
state
!=
EVENT_QUEUED
)
continue
;
if
(
event
->
sender
->
process
==
process
)
{
assert
(
event
->
sender
->
debug_event
==
event
);
event
->
status
=
DBG_CONTINUE
;
event
->
state
=
EVENT_CONTINUED
;
wake_up
(
&
event
->
obj
,
0
);
unlink_event
(
debug_ctx
,
event
);
/* from queued debug event */
resume_process
(
process
);
break
;
}
if
(
event
->
sender
->
process
!=
process
)
continue
;
assert
(
event
->
state
!=
EVENT_CONTINUED
);
event
->
status
=
DBG_CONTINUE
;
event
->
state
=
EVENT_CONTINUED
;
wake_up
(
&
event
->
obj
,
0
);
unlink_event
(
debug_ctx
,
event
);
/* from queued debug event */
resume_process
(
process
);
}
/* remove relationships between process and its debugger */
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment