From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5097 invoked by alias); 20 Jan 2010 19:12:07 -0000 Received: (qmail 5086 invoked by uid 22791); 20 Jan 2010 19:12:06 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 20 Jan 2010 19:12:02 +0000 Received: (qmail 30288 invoked from network); 20 Jan 2010 19:12:00 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 20 Jan 2010 19:12:00 -0000 From: Pedro Alves To: gdb-patches@sourceware.org Subject: Re: [RFA] windows: do not crash if inferior Date: Wed, 20 Jan 2010 19:12:00 -0000 User-Agent: KMail/1.9.10 Cc: Christopher Faylor References: <1C9A707A-AE7C-4947-A9DA-F105674F81AE@adacore.com> <20100120161549.GA24063@ednor.casa.cgf.cx> <20100120173746.GA27289@ednor.casa.cgf.cx> In-Reply-To: <20100120173746.GA27289@ednor.casa.cgf.cx> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <201001201912.12671.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: 2010-01/txt/msg00510.txt.bz2 On Wednesday 20 January 2010 17:37:46, Christopher Faylor wrote: > Actually, how about something like this instead? I used the same wording as fork-child.c > after seeing Pedro's note. > + if (!windows_initialization_done) > + error (_("During startup program exited with code 0x%x."), (unsigned int) current_event.u.ExitProcess.dwExitCode); I think you should call target_mourn_inferior before throwing, to unpush the target_ops, clear inferior_ptid and delete any thread the OS had already reported, and maybe other things. You'll also want to call target_terminal_ours. -- Pedro Alves