From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21514 invoked by alias); 23 Jun 2008 18:36:53 -0000 Received: (qmail 21504 invoked by uid 22791); 23 Jun 2008 18:36:52 -0000 X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.4) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 23 Jun 2008 18:36:35 +0000 Received: (qmail 2386 invoked from network); 23 Jun 2008 18:36:33 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 23 Jun 2008 18:36:33 -0000 From: Pedro Alves To: gdb@sourceware.org, Eli Zaretskii Subject: Re: How to catch GDB crash Date: Mon, 23 Jun 2008 18:36:00 -0000 User-Agent: KMail/1.9.9 Cc: Michael Snyder , divis1969@mail.ru References: <1214241124.3601.1180.camel@localhost.localdomain> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200806231936.32289.pedro@codesourcery.com> X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-06/txt/msg00223.txt.bz2 A Monday 23 June 2008 19:23:03, Eli Zaretskii wrote: > > From: Michael Snyder > > Cc: gdb@sourceware.org > > Date: Mon, 23 Jun 2008 10:12:04 -0700 > > > > You're running on a Windows host, right? Doesn't Windows have > > some mechanism for automatically catching a program that is > > crashing, and holding it for the debugger? > That's true, but you need special code in the debugger to be able to > work like that (it's called JIT debugging, btw). And GDB doesn't > (yet) have such code. You can set error_start in the CYGWIN environment variable to point at GDB's executable to have GDB start automatically on an exception (the op reported --host=i686-pc-cygwin), and, for native Windows apps, there is some registry key (I don't remember which) you can set to point to a JIT debugger. Probably a little exe wrapper is needed to translate the incoming args to GDB args, that's all. I can't see what changes in GDB would be required? -- Pedro Alves