Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 May 2001 13:52:06 +0000 (GMT)
From:      diman <diman@asd-g.com>
To:        Jiangyi Liu <gzjyliu@public.guangzhou.gd.cn>
Cc:        freebsd-hackers@FreeBSD.org
Subject:   Re: Weird PT_DETACH
Message-ID:  <Pine.BSF.4.21.0105301340140.201-100000@portal.none.ua>
In-Reply-To: <000b01c0e90a$2ee15d00$a701160a@fatcow>

next in thread | previous in thread | raw e-mail | index | archive | help

	If i understand ptrace(2) manual page correctly,
	you should use 
		ptrace(PT_DETACH,pid,(caddr_t)1,0)
	instead of 
		ptrace(PT_DETACH,pid,0,0) .

	BTW you code is *very hard to debug* on my 4.1.1 :)
	What your uname -a tells you?



On Wed, 30 May 2001, Jiangyi Liu wrote:

> Hi,
> 
> Sorry I didn't point out that my purpose is just to stop the debugging and leave the subprocess alone. It's supposed after PT_DETACH, the subprocess should continue, but it didn't. That's what I felt weird. Any clue?
> 
> ----- Original Message ----- 
> From: "diman" <diman@asd-g.com>
> To: "Jiangyi Liu" <gzjyliu@public.guangzhou.gd.cn>
> Cc: <freebsd-hackers@FreeBSD.ORG>
> Sent: Wednesday, May 30, 2001 8:54 PM
> Subject: Re: Weird PT_DETACH
> 
> 
> > 
> > 
> > To attach debugger to a process please use PT_ATTACH
> > request instead of PT_DETACH. Use PT_DETACH to stop
> > debugging a process and leave it alone.
> > 
> 
> 


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0105301340140.201-100000>