Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F112530613
D32726.id97654.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
818 B
Referenced Files
None
Subscribers
None
D32726.id97654.diff
View Options
Index: sys/kern/subr_syscall.c
===================================================================
--- sys/kern/subr_syscall.c
+++ sys/kern/subr_syscall.c
@@ -261,10 +261,16 @@
* the next stop is reported as a syscall exit by
* linux_ptrace_status().
*/
- if ((td->td_dbgflags & TDB_EXEC) != 0 &&
- SV_PROC_ABI(td->td_proc) == SV_ABI_LINUX) {
- ptracestop(td, SIGTRAP, NULL);
- td->td_dbgflags &= ~TDB_EXEC;
+ if (traced && (td->td_dbgflags & TDB_EXEC) != 0 &&
+ SV_PROC_ABI(p) == SV_ABI_LINUX) {
+ PROC_LOCK(p->p_pptr);
+ if (SV_PROC_ABI(p->p_pptr) == SV_ABI_LINUX) {
+ PROC_UNLOCK(p->p_pptr);
+ ptracestop(td, SIGTRAP, NULL);
+ td->td_dbgflags &= ~TDB_EXEC;
+ } else {
+ PROC_UNLOCK(p->p_pptr);
+ }
}
/*
* If tracing the execed process, trap to the debugger
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Mar 20, 10:22 AM (7 h, 43 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17229408
Default Alt Text
D32726.id97654.diff (818 B)
Attached To
Mode
D32726: linux: Add additional ptracestop only if the debugger is Linux
Attached
Detach File
Event Timeline
Log In to Comment