7 Jan
2002
7 Jan
'02
2:06 p.m.
[I'm not sure what you are doing but...]
Robert Lunnon <bobNoSpaM(a)yarrabee.net.au> writes:
Here is what the Sun man page says about Ptrace, with apologies to sun, you can find this page at docs.sun.com. Not the comment for call 0 (TRACEME) and ESRCH in the error section
But there has to be some way to attach to a running process.
Yes, ptrace(PTRACE_ATTACH, ...) should work I believe. Haven't tried though.
What happens when you do an attach in gdb? Does it do a ptrace?
I'm not sure. Here is a trace of gdb trying to attach to a bash process (pid 11664).