From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11633 invoked by alias); 8 Jun 2009 14:31:26 -0000 Received: (qmail 11620 invoked by uid 22791); 8 Jun 2009 14:31:24 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 08 Jun 2009 14:31:16 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id CBCF710F6B; Mon, 8 Jun 2009 14:31:13 +0000 (GMT) Received: from caradoc.them.org (209.195.188.212.nauticom.net [209.195.188.212]) by nan.false.org (Postfix) with ESMTP id A1EBE10F6A; Mon, 8 Jun 2009 14:31:13 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1MDfsV-0003u0-LJ; Mon, 08 Jun 2009 10:31:11 -0400 Date: Mon, 08 Jun 2009 14:31:00 -0000 From: Daniel Jacobowitz To: Pedro Alves Cc: gdb-patches@sourceware.org Subject: Re: Refuse following the vfork parent if not letting the child run. Message-ID: <20090608143111.GA14456@caradoc.them.org> Mail-Followup-To: Pedro Alves , gdb-patches@sourceware.org References: <200906081431.38913.pedro@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200906081431.38913.pedro@codesourcery.com> User-Agent: Mutt/1.5.17 (2008-05-11) 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: 2009-06/txt/msg00174.txt.bz2 On Mon, Jun 08, 2009 at 02:31:38PM +0100, Pedro Alves wrote: > A patched GDB shows this: > > (gdb) set detach-on-fork off > (gdb) start > Temporary breakpoint 1 at 0x4005c0: file ../../../src/gdb/testsuite/gdb.base/foll-vfork.c, line 12. > Starting program: /home/pedro/gdb/sspaces/build/gdb/testsuite/gdb.base/foll-vfork > > Temporary breakpoint 1, main () at ../../../src/gdb/testsuite/gdb.base/foll-vfork.c:12 > 12 pid = vfork (); > (gdb) n > warning: Can not debug the parent of a vfork in the foreground if not letting > the child run until it execs or exits, as it would deadlock the terminal. > 0x00007ffff789aee4 in vfork () from /lib/libc.so.6 > (gdb) None of your explanation, the patch, or the example output tells me what GDB is doing instead :-) IOW, I think a "warning" about the situation here is strange; something has happened, and we don't say what. Is this actually a fork-following error, and we've stopped execution? -- Daniel Jacobowitz CodeSourcery