From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5219 invoked by alias); 8 Apr 2009 23:12:00 -0000 Received: (qmail 5211 invoked by uid 22791); 8 Apr 2009 23:11:59 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.4) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 08 Apr 2009 23:11:56 +0000 Received: (qmail 9081 invoked from network); 8 Apr 2009 23:11:54 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 8 Apr 2009 23:11:54 -0000 From: Pedro Alves To: Joel Brobecker Subject: Re: [patch] release handle on object files after program exits Date: Wed, 08 Apr 2009 23:12:00 -0000 User-Agent: KMail/1.9.10 Cc: gdb-patches@sourceware.org References: <20090403164347.GN16605@adacore.com> <200904081814.46748.pedro@codesourcery.com> <20090408223829.GI7535@adacore.com> In-Reply-To: <20090408223829.GI7535@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200904090012.36584.pedro@codesourcery.com> 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-04/txt/msg00165.txt.bz2 On Wednesday 08 April 2009 23:38:29, Joel Brobecker wrote: > Looks like generic_mourn_inferior is not necessarily called at > the end of the execution of the program. Lots of targets actually > call it at the end of their own mourn_inferior, but it is conceivable > that some may not. Hmmmm, all process_stratum targets do, but yes, I can imagine a target not calling it. We might have one internally --- remote targets where a "process exit" is just an event and still leaves execution in the target. Oh, and when debugging multi-forks in linux, and one of the forks exits, we skip the normal mourning tail end. (Gosh, how the checkpoints support is in the way for multiprocess...) Not that that matters much for Windows though. > But you do have a point. =A0How about the following patch instead? > Instead of closing all descriptors before calling the mourn_inferior > routine, it does it after. Looks fine to me. Thanks! --=20 Pedro Alves