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
699d3cf8
Commit
699d3cf8
authored
Nov 12, 1999
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added use_ptrace flag to disable ptrace usage. Should eventually be
made into an option.
parent
c38cb012
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
thread.c
server/thread.c
+2
-1
No files found.
server/thread.c
View file @
699d3cf8
...
@@ -82,6 +82,7 @@ static const struct object_ops thread_ops =
...
@@ -82,6 +82,7 @@ static const struct object_ops thread_ops =
destroy_thread
destroy_thread
};
};
static
const
int
use_ptrace
=
1
;
/* set to 0 to disable ptrace */
static
struct
thread
*
first_thread
;
static
struct
thread
*
first_thread
;
/* allocate the buffer for the communication with the client */
/* allocate the buffer for the communication with the client */
...
@@ -292,7 +293,7 @@ void wait4_thread( struct thread *thread, int signal )
...
@@ -292,7 +293,7 @@ void wait4_thread( struct thread *thread, int signal )
static
int
attach_thread
(
struct
thread
*
thread
)
static
int
attach_thread
(
struct
thread
*
thread
)
{
{
/* this may fail if the client is already being debugged */
/* this may fail if the client is already being debugged */
if
(
ptrace
(
PTRACE_ATTACH
,
thread
->
unix_pid
,
0
,
0
)
==
-
1
)
return
0
;
if
(
!
use_ptrace
||
(
ptrace
(
PTRACE_ATTACH
,
thread
->
unix_pid
,
0
,
0
)
==
-
1
)
)
return
0
;
if
(
debug_level
)
fprintf
(
stderr
,
"ptrace: attached to pid %d
\n
"
,
thread
->
unix_pid
);
if
(
debug_level
)
fprintf
(
stderr
,
"ptrace: attached to pid %d
\n
"
,
thread
->
unix_pid
);
thread
->
attached
=
1
;
thread
->
attached
=
1
;
wait4_thread
(
thread
,
SIGSTOP
);
wait4_thread
(
thread
,
SIGSTOP
);
...
...
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