From owner-freebsd-current@FreeBSD.ORG Sat Jun 30 15:25:41 2007 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 72CD216A400 for ; Sat, 30 Jun 2007 15:25:41 +0000 (UTC) (envelope-from rpaulo@fnop.net) Received: from core.fnop.net (mx.fnop.net [82.102.11.82]) by mx1.freebsd.org (Postfix) with ESMTP id E1C4313C4B9 for ; Sat, 30 Jun 2007 15:25:40 +0000 (UTC) (envelope-from rpaulo@fnop.net) Received: from core.fnop.net (mx.fnop.net [82.102.11.82]) by core.fnop.net (Postfix) with ESMTP id 41282690C54; Sat, 30 Jun 2007 16:21:16 +0100 (WEST) Received: by core.fnop.net (Postfix, from userid 1015) id 01926690C5D; Sat, 30 Jun 2007 16:21:15 +0100 (WEST) X-Spam-Checker-Version: SpamAssassin 3.1.7 (2006-10-05) on core.fnop.net X-Spam-Level: X-Spam-Status: No, score=0.4 required=5.0 tests=AWL,BAYES_00, RCVD_IN_SORBS_DUL,RCVD_IN_SORBS_WEB autolearn=no version=3.1.7 Received: from epsilon.local.fnop.net (unknown [83.144.140.90]) by core.fnop.net (Postfix) with ESMTP id 56E60690C54; Sat, 30 Jun 2007 16:21:14 +0100 (WEST) Date: Sat, 30 Jun 2007 16:25:29 +0100 Message-ID: <86zm2hv506.wl%rpaulo@fnop.net> From: Rui Paulo To: Steve Kargl In-Reply-To: <20070630150448.GA70741@troutmask.apl.washington.edu> References: <20070630150448.GA70741@troutmask.apl.washington.edu> User-Agent: Wanderlust/2.15.5 (Almost Unreal) Emacs/21.3 Mule/5.0 (SAKAKI) X-cite-me: rpaulo MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Virus-Scanned: ClamAV using ClamSMTP Cc: Michiel Boland , freebsd-current@freebsd.org Subject: Re: tcsh hangs in sigsuspend X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Jun 2007 15:25:41 -0000 At Sat, 30 Jun 2007 08:04:48 -0700, Steve Kargl wrote: > > On Sat, Jun 30, 2007 at 04:41:42PM +0200, Michiel Boland wrote: > > Hi. I can no longer do simple things like > > > > kill `cat pidfile` > > > > in tcsh. > > > > After some debugging I noticed that tcsh hangs in sigsuspend in line 512 > > of sh.proc.c. So I guess it (tcsh) executed 'cat pidfile', and now waits > > for the process to terminate. But unless I'm not looking properly, there > > appears to be a race condition here. Tcsh blocks the SIGCHLD signal > > *after* it forks the child, not before. So the child could wel have exited > > between the call to fork and the call to sigprocmask. In that case, would > > not the sigsuspend hang forever? > > > > Also, I noticed that gdb gets very confused if I try to debug tcsh with > > a backticked command like the one above. (I guess this is the same as > > bin/112408) > > > > I suspect it is the same problem. Unfortunately, the author of > tcsh does not have a publicly available source tree, so one cannot > determine if the problem is fixed. It looks like you've managed > to go beyond the limited debugging I did in bin/112408. Hopefully, > this gets addressed before 7.0 is released. But you can consult the bug tracking system at http://bugs.gw.com/ Hope this helps. -- Rui Paulo