From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27686 invoked by alias); 21 Jan 2010 13:58:48 -0000 Received: (qmail 27678 invoked by uid 22791); 21 Jan 2010 13:58:48 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 21 Jan 2010 13:58:43 +0000 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o0LDwfFJ012576 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 21 Jan 2010 08:58:42 -0500 Received: from host0.dyn.jankratochvil.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx03.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o0LDwdCO007919 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 21 Jan 2010 08:58:41 -0500 Received: from host0.dyn.jankratochvil.net (localhost [127.0.0.1]) by host0.dyn.jankratochvil.net (8.14.3/8.14.3) with ESMTP id o0LDwdka005362; Thu, 21 Jan 2010 14:58:39 +0100 Received: (from jkratoch@localhost) by host0.dyn.jankratochvil.net (8.14.3/8.14.3/Submit) id o0LDwcGI005360; Thu, 21 Jan 2010 14:58:38 +0100 Date: Thu, 21 Jan 2010 13:58:00 -0000 From: Jan Kratochvil To: Doug Evans Cc: gdb-patches@sourceware.org Subject: Re: [patch] print a more useful error message for "gdb core" Message-ID: <20100121135838.GA5211@host0.dyn.jankratochvil.net> References: <20100120235605.607D284413@ruffy.mtv.corp.google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-08-17) 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/msg00521.txt.bz2 On Thu, 21 Jan 2010 01:12:49 +0100, Doug Evans wrote: > On Wed, Jan 20, 2010 at 3:56 PM, Doug Evans wrote: > > If the user accidentally does "gdb core" gdb currently prints: > > > > "/foo/bar": not in executable format: File format not recognized > > > > This patch prints a more useful error message for this particular case: > > > > "/foo/bar" is a core file. > > Please specify an executable to debug. I would prefer to try automatically loading it as a core file ("gdb -c core") and to print a warning instead of error. Fedora GDB is patched for build-id (still not submitted for FSF) so that it can find the executable in such case. But maybe such change should go in only with the build-id patch itself. Regards, Jan