This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[RFA] aix-thread.c: Allow retargeting of threaded targets
- From: Corinna Vinschen <vinschen at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Thu, 22 Aug 2002 15:54:02 +0200
- Subject: [RFA] aix-thread.c: Allow retargeting of threaded targets
- Reply-to: gdb-patches at sources dot redhat dot com
Hi,
the following problem occurs on AIX, when the user examines a core file
of a threaded target:
$ gdb -nw application core
[...]
(gdb) run
Starting program: application
You can't do that without a process to debug.
(gdb) quit
The program is running. Exit anyway? (y or n) y
You can't do that without a process to debug.
(gdb)
Even detaching from the core doesn't help since the current code
doesn't detach in a way so that the aix-thread code would be able
to reinitializes on "run".
The following fix corrects the detach command in that case, so that
the user can run and/or quit gdb by explicitely detaching.
This doesn't solve the still outstanding problem, that the "run"
command should implicitely detach from the previous target, if that
was a core file.
Corinna
ChangeLog:
2002-08-21 Corinna Vinschen <vinschen@redhat.com>
* aix-thread.c (aix_thread_detach): Disable thread debugging on
detach to allow reinitialization.
Index: aix-thread.c
===================================================================
RCS file: /cvs/src/src/gdb/aix-thread.c,v
retrieving revision 1.13
diff -u -p -r1.13 aix-thread.c
--- aix-thread.c 27 Jul 2002 00:06:19 -0000 1.13
+++ aix-thread.c 22 Aug 2002 13:41:35 -0000
@@ -926,7 +926,7 @@ aix_thread_attach (char *args, int from_
static void
aix_thread_detach (char *args, int from_tty)
{
- pd_deactivate ();
+ pd_disable ();
base_target.to_detach (args, from_tty);
}
--
Corinna Vinschen
Cygwin Developer
Red Hat, Inc.
mailto:vinschen@redhat.com