From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14821 invoked by alias); 25 May 2006 09:06:54 -0000 Received: (qmail 14812 invoked by uid 22791); 25 May 2006 09:06:53 -0000 X-Spam-Check-By: sourceware.org Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 25 May 2006 09:06:48 +0000 Received: from Relay2.suse.de (mail2.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id 3F97B1EBC2; Thu, 25 May 2006 11:06:44 +0200 (CEST) From: Andreas Schwab To: Wu Zhou Cc: gdb@sourceware.org Subject: Re: expected behavior when a signal is sent to the ptraced child References: X-Yow: Boy, am I glad it's only 1971... Date: Thu, 25 May 2006 13:06:00 -0000 In-Reply-To: (Wu Zhou's message of "Thu, 25 May 2006 10:36:37 +0800 (CST)") Message-ID: User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit 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-05/txt/msg00368.txt.bz2 Wu Zhou writes: > What I expect is the parent will at least output: > > stopped by signal 5 > > What is the problem here? Did I make something wrong? You need to use waitpid/wait4 and add WUNTRACED to the options parameter. Without that you'll never receive notification of stopped processes. Andreas. -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."