From owner-freebsd-current@FreeBSD.ORG Mon May 19 23:45:47 2003 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 C432137B401; Mon, 19 May 2003 23:45:47 -0700 (PDT) Received: from stork.mail.pas.earthlink.net (stork.mail.pas.earthlink.net [207.217.120.188]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0475243F93; Mon, 19 May 2003 23:45:47 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from user-38lc0ps.dialup.mindspring.com ([209.86.3.60] helo=mindspring.com) by stork.mail.pas.earthlink.net with asmtp (SSLv3:RC4-MD5:128) (Exim 3.33 #1) id 19I0sb-0004VZ-00; Mon, 19 May 2003 23:45:46 -0700 Message-ID: <3EC9CECF.BA6F0DC1@mindspring.com> Date: Mon, 19 May 2003 23:44:31 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Robert Watson References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-ELNK-Trace: b1a02af9316fbb217a47c185c03b154d40683398e744b8a4be5a21c7d6cd99b45e725da2a74a14f2667c3043c0873f7e350badd9bab72f9c350badd9bab72f9c cc: re@FreeBSD.org cc: current@FreeBSD.org Subject: Re: 5.1-RELEASE TODO 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: Tue, 20 May 2003 06:45:48 -0000 Robert Watson wrote: > On Mon, 19 May 2003, Terry Lambert wrote: > > According to chapter 12 of the "Go Solo 2" book, this is a bogus thing > > to do. Callers are required to take a critical section over the calls > > to the dl* functions because the dlerror() function uses a static buffer > > that can be overwritten in a multi-threaded environment. > > Sadly, that insight doesn't seem to have influenced the development > practices of a number of major application vendors :-(. Then I guess their software breaks on FreeBSD and several other platforms. Like Mozilla and Java break because they assume bad things about the scheduler not being able to switch threads on a priority basis following a return from an involuntary process preemption... If you're serious about making the FreeBSD implementation conform to some defacto "standard" defined by how people misuse API's, then it's probably about time that sockaddr_in didn't require its "unused" fields to be zeroed, just like Linux and Solaris let you leave crap in the "unused" portions of the structure. That's the main reason the SLPv2 reference implementation doesn't work on FreeBSD (it was written by a Linux weenie who grabbed his sockaddr_in on a stack variable, and failed to bzero it like FreeBSD needs, before filling in the entries we supposedly care about for the connect/bind calls). Alternately, when we run into non-conforming applications, we could send patches to the maintainers to make them conform, instead of bending ourselves into some twisted image of Linux... -- Terry