From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29350 invoked by alias); 20 Jun 2006 18:31:21 -0000 Received: (qmail 29338 invoked by uid 22791); 20 Jun 2006 18:31:19 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Tue, 20 Jun 2006 18:31:07 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1Fsl0D-00083E-SX for gdb@sourceware.org; Tue, 20 Jun 2006 14:31:06 -0400 Date: Tue, 20 Jun 2006 20:08:00 -0000 From: Daniel Jacobowitz To: gdb@sourceware.org Subject: Re: GDB does not respond to CTRL+Z and CTRL+C Message-ID: <20060620183105.GA30908@nevyn.them.org> Mail-Followup-To: gdb@sourceware.org References: <200606201827.25482.bartoschek@or.uni-bonn.de> <200606202002.05813.bartoschek@or.uni-bonn.de> <20060620180453.GA30199@nevyn.them.org> <200606202018.56169.bartoschek@or.uni-bonn.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200606202018.56169.bartoschek@or.uni-bonn.de> User-Agent: Mutt/1.5.11+cvs20060403 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-06/txt/msg00154.txt.bz2 On Tue, Jun 20, 2006 at 08:18:56PM +0200, Christoph Bartoschek wrote: > > > Then it is likely that your program is blocking the signal. GDB > > doesn't handle either directly; it forwards them to the program and > > lets the OS handle delivery. > > I do not think that we block the signal. However, I have to check the code. > But this does not explain why I am able to use CTRL+Z and CTRL+C as intended > after sending SIGSTOP directly to GDB and foregrounding it again. > > CTRL+Z and CTRL+C are only ignored until GDB receives the first SIGSTOP via > the kill command. If the signals are blocked, then I would expect that GDB > behaves similarly before and after SIGSTOP. I don't know what's going on and can't reproduce it; you'd have to figure this out yourself, I'm afraid. > If the signals are really blocked, how should one interrupt debugging to set > breakpoints for example? Try sending the program (not GDB) a SIGSTOP. Don't confuse this with CTRL-Z; that sends SIGTSTP, which can be blocked, but SIGSTOP can not. -- Daniel Jacobowitz CodeSourcery