From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21676 invoked by alias); 15 Jun 2005 14:16:29 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 21666 invoked by uid 22791); 15 Jun 2005 14:16:26 -0000 Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Wed, 15 Jun 2005 14:16:26 +0000 Received: from drow by nevyn.them.org with local (Exim 4.50) id 1DiYgq-0003j7-Op; Wed, 15 Jun 2005 10:16:24 -0400 Date: Wed, 15 Jun 2005 14:16:00 -0000 From: Daniel Jacobowitz To: Hamish Rodda Cc: gdb@sources.redhat.com Subject: Re: Unwinding stack past main() when it has another name Message-ID: <20050615141624.GB14209@nevyn.them.org> Mail-Followup-To: Hamish Rodda , gdb@sources.redhat.com References: <200506152247.07232.rodda@kde.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200506152247.07232.rodda@kde.org> User-Agent: Mutt/1.5.8i X-SW-Source: 2005-06/txt/msg00158.txt.bz2 On Wed, Jun 15, 2005 at 10:46:37PM +1000, Hamish Rodda wrote: > Hi, > > I'm just curious if there's a better solution for a problem I've come up > against recently. I have been using gdb 6.3 and finding that all of my kde > program backtraces contain hundreds of irrelevant and corrupt-looking frames. > Upgrading to cvs fixed most of the problem (the corrupt looking frames), but > some frames still remain before the main function, which in kde programs is > called kdemain(). > > Is there something the kde sources can do to have gdb recognise kdemain() as > the replacement main() function, and thus prevent gdb from unwinding past it? Is there really no main() on the backtrace? There's no easy way in C to mark another function as main or as not-backtraceable. -- Daniel Jacobowitz CodeSourcery, LLC