This is the mail archive of the
gdb-cvs@sources.redhat.com
mailing list for the GDB project.
src/gdb ChangeLog lin-lwp.c config/i386/nm-linux.h
- To: gdb-cvs at sourceware dot cygnus dot com
- Subject: src/gdb ChangeLog lin-lwp.c config/i386/nm-linux.h
- From: kettenis at sourceware dot cygnus dot com
- Date: 14 Oct 2001 11:30:38 -0000
CVSROOT: /cvs/src
Module name: src
Changes by: kettenis@sources.redhat.com 2001-10-14 04:30:37
Modified files:
gdb : ChangeLog lin-lwp.c
gdb/config/i386: nm-linux.h
Log message:
Fix attaching to cloned processes. This fixes PR gdb/61.
* lin-lwp.c (struct lwp_info): Add new member `cloned'.
(is_cloned) Removed.
(lin_lwp_attach_lwp): Don't call stop_wait_callback. Instead call
waitpid explicitly. Mark the LWP as cloned if waitpid fails and
retry with __WCLONE flag.
(lin_lwp_attach): Likewise. Warn if attaching to a cloned process.
(detach_callback): Replace use of is_cloned with explicit check on
LWP id and process id.
(stop_wait_callback): Replace use of is_cloned with check if LWP
is marked as cloned.
[CHILD_WAIT] (child_wait): New function.
(lin_lwp_wait): Replace use of is_cloned with check if LWP is
marked as cloned. Mark newly detected LWPs as cloned if detected
by waitpid with __WCLONE flag.
(kill_wait_callback): Replace use of is_cloned with check if LWP
is marked as cloned.
* config/i386/nm-linux.h (struct target_waitstatus): Add forward
declaration.
(child_wait): Add prototype.
(CHILD_WAIT): Define.
Patches:
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.1650&r2=1.1651
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/gdb/lin-lwp.c.diff?cvsroot=src&r1=1.29&r2=1.30
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/gdb/config/i386/nm-linux.h.diff?cvsroot=src&r1=1.13&r2=1.14