lkml.org 
[lkml]   [1997]   [Nov]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Reading the context of a process
On Tue, 25 Nov 1997, Arun Sharma wrote:

> Can anyone give me a hint about how to read the context (registers,
> memory) of a process stopped by SIGSTOP ?
>
> I know that debuggers use ptrace system calls. But the processes
> need to have a parent-child relationship ? Is it possible to do it via
> /proc ?

You can do a PTRACE_ATTACH to ptrace an arbitrary process. This is
how gdb and strace can attach to any running process.

Mike

--
.----------------------------------------------------------------------.
| Mike Jagdis | Internet: mailto:mike@roan.co.uk |
| Roan Technology Ltd. | |
| 54A Peach Street, Wokingham | Telephone: +44 118 989 0403 |
| RG40 1XG, ENGLAND | Fax: +44 118 989 1195 |
`----------------------------------------------------------------------'


\
 
 \ /
  Last update: 2005-03-22 13:40    [W:0.035 / U:1.588 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site