From owner-freebsd-python@FreeBSD.ORG Tue Feb 24 14:26:24 2004 Return-Path: Delivered-To: freebsd-python@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4927916A4CE; Tue, 24 Feb 2004 14:26:24 -0800 (PST) Received: from mail.pcnet.com (mail.pcnet.com [204.213.232.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id DF08743D2F; Tue, 24 Feb 2004 14:26:23 -0800 (PST) (envelope-from eischen@vigrid.com) Received: from mail.pcnet.com (mail.pcnet.com [204.213.232.4]) by mail.pcnet.com (8.12.10/8.12.1) with ESMTP id i1OMQDDF005092; Tue, 24 Feb 2004 17:26:13 -0500 (EST) Date: Tue, 24 Feb 2004 17:26:13 -0500 (EST) From: Daniel Eischen X-Sender: eischen@pcnet5.pcnet.com To: Jeremy Messenger In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: freebsd-threads@freebsd.org cc: python@freebsd.org cc: Julian Elischer cc: Hye-Shik Chang Subject: Re: Need the help on debug the Python VS libpthread.. X-BeenThere: freebsd-python@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: FreeBSD-specific Python issues List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Feb 2004 22:26:24 -0000 On Tue, 24 Feb 2004, Jeremy Messenger wrote: > On Tue, 24 Feb 2004 10:57:32 -0800 (PST), Julian Elischer > wrote: > > > > > > > On Tue, 24 Feb 2004, Jeremy Messenger wrote: > > > >> Great, thank guys! I now can install net/straw with optimized on > >> libpthread. I am adding -thread in the CC, so the thread developers can > >> catch here too. :-) > > > > so what was fixed between teh quoted mail below and now? > > A workaround (not real fix?) as perky has committed[1]. There's something > wrong with waitpid if it runs as libpthread, since without the workaround > can run fine with libc_r. It is not necessarily a problem with libpthread. waitpid() can return EINTR when interrupted by a signal. If SIGCHLD isn't masked by the thread, then it is certainly plausible that it can get interrupted by it. You may not have seen it with libc_r because it handles signals differently as well as wrap waitpid() so it doesn't block the process. Libpthread doesn't wrap waitpid() except to make it a cancellation point. If its returning EINTR, I would suspect that it has received a signal. -- Dan Eischen