From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2575 invoked by alias); 20 Jan 2009 15:32:48 -0000 Received: (qmail 2504 invoked by uid 22791); 20 Jan 2009 15:32:47 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00,J_CHICKENPOX_39 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 20 Jan 2009 15:32:43 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id D25E410635; Tue, 20 Jan 2009 15:32:38 +0000 (GMT) Received: from caradoc.them.org (209.195.188.212.nauticom.net [209.195.188.212]) by nan.false.org (Postfix) with ESMTP id 744DC105B9; Tue, 20 Jan 2009 15:32:38 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1LPIak-0003YX-0f; Tue, 20 Jan 2009 10:32:38 -0500 Date: Tue, 20 Jan 2009 15:32:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sourceware.org Cc: Michael Snyder Subject: Re: RFC: Do not call write_pc for "signal SIGINT" Message-ID: <20090120153237.GA11920@caradoc.them.org> Mail-Followup-To: gdb-patches@sourceware.org, Michael Snyder References: <20080828155520.GA23110@caradoc.them.org> <48B6E9F4.5080403@vmware.com> <20080828181841.GA30866@caradoc.them.org> <48B6EFBD.2090203@vmware.com> <20080828223232.GA6407@caradoc.them.org> <20081117215501.GA19975@caradoc.them.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20081117215501.GA19975@caradoc.them.org> User-Agent: Mutt/1.5.17 (2008-05-11) 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: 2009-01/txt/msg00426.txt.bz2 On Mon, Nov 17, 2008 at 04:55:01PM -0500, Daniel Jacobowitz wrote: > Here it is with a testcase. > > To recap: there is a tricky bug in signal_command. If any non-zero > signal is specified, it performs a jump to the current address instead > of just resuming there. This causes any pending system call to be > interrupted, in a way that leaves a kernel-internal value in the > return value register. If we just delete that code, and the FIXME > that goes with it, the right thing happens: instead of "Unknown > error 514", the system call returns EINTR and the loop continues. > 2008-11-17 Daniel Jacobowitz > > PR gdb/2241 > * infcmd.c (signal_command): Do not specify a resume PC. > > 2008-11-17 Daniel Jacobowitz > > PR gdb/2241 > * gdb.base/interrupt.c (sigint_handler): New. > (main): Install a SIGINT handler if SIGNALS is defined. Exit > on error. > * gdb.base/interrupt.exp: Define SIGNALS unless gdb,nosignals. > Test "signal SIGINT". I have checked this in. -- Daniel Jacobowitz CodeSourcery