From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7281 invoked by alias); 16 Mar 2006 17:11:31 -0000 Received: (qmail 7273 invoked by uid 22791); 16 Mar 2006 17:11:30 -0000 X-Spam-Check-By: sourceware.org Received: from smarthost3.mail.uk.easynet.net (HELO smarthost3.mail.uk.easynet.net) (212.135.6.13) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 16 Mar 2006 17:11:28 +0000 Received: from [217.207.128.220] (helo=pennyblack.transitives.com) by smarthost3.mail.uk.easynet.net with esmtp (Exim 4.10) id 1FJw0Q-000FCh-00 for gdb@sources.redhat.com; Thu, 16 Mar 2006 17:11:22 +0000 Received: from internal.transitives.com ([172.16.0.1] helo=okra.transitives.com) by pennyblack.transitives.com with esmtp (Exim 4.50) id 1FJvv7-0005lG-4s for gdb@sources.redhat.com; Thu, 16 Mar 2006 17:05:53 +0000 Subject: Fully automating GDB (aka how to make canned command strings see the exit status) From: Alex Bennee Reply-To: alexjb@transitive.com To: gdb@sources.redhat.com Content-Type: text/plain Date: Thu, 16 Mar 2006 17:18:00 -0000 Message-Id: <1142529081.5372.14.camel@okra.transitives.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit 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-03/txt/msg00100.txt.bz2 Hi, I've got a program I'm trying to debug that crashes on a very intermittent basis. I suspect the core dumps I'm getting are incomplete so I would like to try and catch the the crash live in gdb. I figure a canned script to run the program is the answer. However how do I tell if the program has exited successfully (in which case I can run again) to hitting the SEG and staying put for when I come back in the morning? -- Alex, homepage: http://www.bennee.com/~alex/ TV is chewing gum for the eyes. -- Frank Lloyd Wright