Received: from pianosa.catch22.org (pianosa.catch22.org [64.81.48.19]) by postgresql.org (8.11.3/8.11.4) with ESMTP id g1F28eE30395 for ; Thu, 14 Feb 2002 21:08:40 -0500 (EST) (envelope-from dbt@meat.net) Received: by pianosa.catch22.org (Postfix, from userid 1000) id 39352363; Thu, 14 Feb 2002 18:08:43 -0800 (PST) Date: Thu, 14 Feb 2002 18:08:42 -0800 From: David Terrell To: Tom Lane Cc: pgsql-hackers@postgresql.org Subject: Re: RTLD_LAZY considered harmful (Re: pltlc and pltlcu Message-ID: <20020214180842.B23916@pianosa.catch22.org> Reply-To: David Terrell References: <25459.1013389242@sss.pgh.pa.us> <18523.1013474997@sss.pgh.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <18523.1013474997@sss.pgh.pa.us>; from tgl@sss.pgh.pa.us on Mon, Feb 11, 2002 at 07:49:57PM -0500 X-vi: Version 1.79 (10/23/96) The CSRG, University of California, Berkeley. X-Nethack: You feel like someone is making a pointless Nethack reference.--More-- X-Uptime: 6:05PM up 2:12, 17 users, load averages: 0.40, 0.37, 0.35 X-Archive-Number: 200202/544 X-Sequence-Number: 18839 On Mon, Feb 11, 2002 at 07:49:57PM -0500, Tom Lane wrote: > I also believe that this will produce more consistent cross-platform > behavior: so far as I could learn from googling, systems that do not > define RTLD_NOW/RTLD_LAZY all act as though the mode were RTLD_NOW, > ie, immediate binding. > > Any objections to modifying all the port/dynloader files this way? OpenBSD: The dlopen() function takes a name of a shared object as its first argu- ment. The shared object is mapped into the address space, relocated, and its external references are resolved in the same way as is done with the implicitly loaded shared libraries at program startup. The path argument can either be an absolute pathname or it can be of the form ``lib.so[.xx[.yy]]'' in which case the same library search rules apply that are used for ``intrinsic'' shared library searches. The second argument currently has no effect, but should be set to DL_LAZY for future compatibility. That last sentence being key.... -- David Terrell | "War is peace, Prime Minister, Nebcorp | freedom is slavery, dbt@meat.net | ignorance is strength http://wwn.nebcorp.com/ | Dishes are clean." - Chris Fester