From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31373 invoked by alias); 21 May 2010 15:06:36 -0000 Received: (qmail 31323 invoked by uid 22791); 21 May 2010 15:06:36 -0000 X-SWARE-Spam-Status: No, hits=-5.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD 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; Fri, 21 May 2010 15:06:31 +0000 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o4LF6Uq1024848 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 21 May 2010 11:06:30 -0400 Received: from host0.dyn.jankratochvil.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o4LF6SkK001447 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 21 May 2010 11:06:29 -0400 Received: from host0.dyn.jankratochvil.net (localhost [127.0.0.1]) by host0.dyn.jankratochvil.net (8.14.4/8.14.4) with ESMTP id o4LF6Rto021371; Fri, 21 May 2010 17:06:27 +0200 Received: (from jkratoch@localhost) by host0.dyn.jankratochvil.net (8.14.4/8.14.4/Submit) id o4LF6QUe021370; Fri, 21 May 2010 17:06:26 +0200 Date: Fri, 21 May 2010 15:07:00 -0000 From: Jan Kratochvil To: Mark Kettenis Cc: gdb-patches@sourceware.org Subject: Re: [patch] Forbid run with a core file loaded Message-ID: <20100521150625.GA21052@host0.dyn.jankratochvil.net> References: <20100521134718.GA17157@host0.dyn.jankratochvil.net> <201005211447.o4LEl7tQ019880@glazunov.sibelius.xs4all.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201005211447.o4LEl7tQ019880@glazunov.sibelius.xs4all.nl> 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-05/txt/msg00487.txt.bz2 On Fri, 21 May 2010 16:47:07 +0200, Mark Kettenis wrote: > > Date: Fri, 21 May 2010 15:47:19 +0200 > > From: Jan Kratochvil > > > > Hi, > > > > there is already a protection against loading a core file when a program is > > running. > > That makes sense. But what you are suggesting doesn't. > > I often start gdb and load a core file to investigate a problem. Then > I set a breakpoint at some point before the crash and run the program > again. This used to work just fine. What do you suggest otherwise? If core-and-then-run should work then we must make working also run-and-then-core (fine with that). With both core file and running process the core file memory gets ignored. So I find unloading a core file as just making the situation more simple. (a) Do you find the "Unload it?" question too distrurbing? (b) Do you find essential to see the core file memory again after the process terminates? Thanks, Jan