From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16859 invoked by alias); 30 Jul 2010 08:14:10 -0000 Received: (qmail 16840 invoked by uid 22791); 30 Jul 2010 08:14:09 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM X-Spam-Check-By: sourceware.org Received: from mail-wy0-f169.google.com (HELO mail-wy0-f169.google.com) (74.125.82.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 30 Jul 2010 08:14:04 +0000 Received: by wyg36 with SMTP id 36so1001900wyg.0 for ; Fri, 30 Jul 2010 01:14:02 -0700 (PDT) Received: by 10.216.11.130 with SMTP id 2mr1253055wex.100.1280477642171; Fri, 30 Jul 2010 01:14:02 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.186.205 with HTTP; Fri, 30 Jul 2010 01:13:42 -0700 (PDT) From: Hui Zhu Date: Fri, 30 Jul 2010 08:14:00 -0000 Message-ID: Subject: [RFA/RFC/DOC] Fix the different between behavior of "detach inferior" "kill inferior" and doc To: gdb-patches ml Cc: Eli Zaretskii Content-Type: text/plain; charset=ISO-8859-1 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-07/txt/msg00572.txt.bz2 Hi, The doc said: @kindex detach inferior @var{infno} @item detach inferior @var{infno} Detach from the inferior identified by @value{GDBN} inferior number @var{infno}, and remove it from the inferior list. @kindex kill inferior @var{infno} @item kill inferior @var{infno} Kill the inferior identified by @value{GDBN} inferior number @var{infno}, and remove it from the inferior list. But when I try this command: (gdb) info inferiors Num Description Executable * 2 1 process 12089 /home/teawater/gdb/1 (gdb) kill inferior 1 (gdb) info inferiors Num Description Executable 2 * 1 /home/teawater/gdb/1 (gdb) Inferior 1 is not removed from list. And I check the code in inferior.c: switch_to_thread (tp->ptid); target_kill (); bfd_cache_close_all (); } Look it doesn't want remove it from inferior list. So I make a patch to update the doc. Thanks, Hui 2010-07-30 Hui Zhu * gdb.texinfo (Inferiors and Programs): Update the introduce of "detach inferior" and "kill inferior". --- doc/gdb.texinfo | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/doc/gdb.texinfo +++ b/doc/gdb.texinfo @@ -2481,12 +2481,12 @@ using the @w{@code{kill inferior}} comma @kindex detach inferior @var{infno} @item detach inferior @var{infno} Detach from the inferior identified by @value{GDBN} inferior number -@var{infno}, and remove it from the inferior list. +@var{infno}. @kindex kill inferior @var{infno} @item kill inferior @var{infno} Kill the inferior identified by @value{GDBN} inferior number -@var{infno}, and remove it from the inferior list. +@var{infno}. @end table After the successful completion of a command such as @code{detach},