From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28715 invoked by alias); 10 Jan 2006 11:30:52 -0000 Received: (qmail 28705 invoked by uid 22791); 10 Jan 2006 11:30:52 -0000 X-Spam-Check-By: sourceware.org Received: from thunder.netspace.net.au (HELO mail.netspace.net.au) (203.10.110.71) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 10 Jan 2006 11:30:48 +0000 Received: from [192.168.0.10] (220-253-60-77.VIC.netspace.net.au [220.253.60.77]) by mail.netspace.net.au (Postfix) with ESMTP id E67C24A203 for ; Tue, 10 Jan 2006 22:30:45 +1100 (EST) Message-ID: <43C39AE9.8030805@netspace.net.au> Date: Tue, 10 Jan 2006 11:30:00 -0000 From: Russell Shaw User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.11) Gecko/20050914 Debian/1.7.11-1 MIME-Version: 1.0 Cc: gdb@sources.redhat.com Subject: Re: Core dumps References: <43C22DD0.5080503@netspace.net.au> <200601091912.k09JC0fp022663@elgar.sibelius.xs4all.nl> In-Reply-To: <200601091912.k09JC0fp022663@elgar.sibelius.xs4all.nl> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-01/txt/msg00074.txt.bz2 Mark Kettenis wrote: >>Date: Mon, 09 Jan 2006 20:33:04 +1100 >>From: Russell Shaw >> >>Hi, >>When i make my code core-dump using abort(), and read the >>core with "target core core", the back-trace shows a corrupted >>stack. How do i make a core dump that has an intact stack i can >>trace thru? Should i use something other than abort()? > > Sorry, but you don't provide nearly enough information to enable us to > answer your question. At least we need to know what OS, what hardware > platform, what version of GDB and what version of GCC you're using. > It'd help us even more if you could provide a typescript of a GDB > session that show us your problem. I'm using debian-sid on a PC. GNU gdb 6.3-debian gcc (GCC) 4.0.3 20051201 (prerelease) (Debian 4.0.2-5) In gdb, i did: (gdb) target core core (gdb) bt I get a long backtrace of "?" and a note saying corrupt stack. I can't get a new core file to happen now, despite the program hitting abort() or raise(11). I have ulimit unlimited.