From owner-freebsd-current@FreeBSD.ORG Wed Mar 3 09:32:38 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CF38416A4CE; Wed, 3 Mar 2004 09:32:38 -0800 (PST) Received: from rwcrmhc13.comcast.net (rwcrmhc13.comcast.net [204.127.198.39]) by mx1.FreeBSD.org (Postfix) with ESMTP id AB04D43D2F; Wed, 3 Mar 2004 09:32:38 -0800 (PST) (envelope-from rodrigc@h00609772adf0.ne.client2.attbi.com) Received: from dibbler.crodrigues.org (h00609772adf0.ne.client2.attbi.com[66.31.45.197]) by comcast.net (rwcrmhc13) with ESMTP id <20040303173238015000qe25e>; Wed, 3 Mar 2004 17:32:38 +0000 Received: from dibbler.crodrigues.org (localhost.crodrigues.org [127.0.0.1]) i23HWfh9086471; Wed, 3 Mar 2004 12:32:41 -0500 (EST) (envelope-from rodrigc@h00609772adf0.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.crodrigues.org (8.12.11/8.12.10/Submit) id i23HWfLn086470; Wed, 3 Mar 2004 12:32:41 -0500 (EST) (envelope-from rodrigc) Date: Wed, 3 Mar 2004 12:32:40 -0500 From: Craig Rodrigues To: David Xu Message-ID: <20040303173240.GA86457@crodrigues.org> References: <20040303061144.GE56622@elvis.mu.org> <404592F5.1060206@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <404592F5.1060206@freebsd.org> User-Agent: Mutt/1.4.1i cc: current@freebsd.org Subject: Re: fix for libpthread X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 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: Wed, 03 Mar 2004 17:32:38 -0000 On Wed, Mar 03, 2004 at 04:10:29PM +0800, David Xu wrote: > >- if (!__isthreaded) > >- PANIC("Spinlock called when not threaded."); > > if (!initialized) > > PANIC("Spinlocks not initialized."); > > /* > > > > > As I saw some reports in the -CURRENT list, the panic is always > triggered by mix up > of libc_r and libpthread in same program. So to avoid other mysterious > crashes, > I'd like keep the code there, it is now used to check the problem. Would it be a good idea to change the wording of this error message to give the user a better idea of how to fix the problem? PANIC("Spinlock called when not threaded.\nPossible problem: program might be linked to both -lpthread and -lc_r, instead of linking only one of them.\n"); Or, something to that effect. -- Craig Rodrigues http://crodrigues.org rodrigc@crodrigues.org