From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28103 invoked by alias); 3 Mar 2008 20:37:29 -0000 Received: (qmail 28093 invoked by uid 22791); 3 Mar 2008 20:37:29 -0000 X-Spam-Check-By: sourceware.org Received: from sibelius.xs4all.nl (HELO sibelius.xs4all.nl) (82.92.89.47) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 03 Mar 2008 20:37:02 +0000 Received: from brahms.sibelius.xs4all.nl (kettenis@localhost.sibelius.xs4all.nl [127.0.0.1]) by brahms.sibelius.xs4all.nl (8.14.1/8.14.1) with ESMTP id m23KZZpS025032; Mon, 3 Mar 2008 21:35:36 +0100 (CET) Received: (from kettenis@localhost) by brahms.sibelius.xs4all.nl (8.14.1/8.14.1/Submit) id m23KZZpQ013528; Mon, 3 Mar 2008 21:35:35 +0100 (CET) Date: Mon, 03 Mar 2008 20:37:00 -0000 Message-Id: <200803032035.m23KZZpQ013528@brahms.sibelius.xs4all.nl> From: Mark Kettenis To: msnyder@specifix.com CC: deuling@de.ibm.com, gdb-patches@sourceware.org, uweigand@de.ibm.com In-reply-to: <1204576131.19253.582.camel@localhost.localdomain> (message from Michael Snyder on Mon, 03 Mar 2008 12:28:51 -0800) Subject: Re: [patch] Add proper error message instead of gdb_assert References: <47CC5332.3020700@de.ibm.com> <200803031955.m23Jt7cj019540@brahms.sibelius.xs4all.nl> <1204576131.19253.582.camel@localhost.localdomain> 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: 2008-03/txt/msg00021.txt.bz2 > From: Michael Snyder > Date: Mon, 03 Mar 2008 12:28:51 -0800 > > On Mon, 2008-03-03 at 20:55 +0100, Mark Kettenis wrote: > > > > > Sorry, but I don't see why your error message is "proper". The > > gdb_assert() should never fail; the fact that it does means that you > > have a bug elsewhere in gdb. > > Isn't that what the "internal error" call is for? > > The fact that there's a bug somewhere else in gdb is not > necessarily a reason to abort the debugging session. > It COULD be that severe -- but I don't think we necessarily > need to assume it is. Sure, that's why we don't use assert(), but have gdb_assert(), which calls internal_error() instead of abort. It's just that gdb_assert() results in a slightly different error message (which hopefuly is more helpful to the poor soul who actually will be fixing the bug).