httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@msoft.com (Jon Teichrow)
Subject Re: RTLD_GLOBAL for DSO?
Date Fri, 10 Jul 1998 17:34:15 GMT
FYI, this will also resolve a problem I'm having.

(from comp.infosystems.www.servers.unix)

On Solaris when I build my module for
DSO configuration, C++ exceptions cause
Apache to core dump.  This is because the
module is not loaded with the RTLD_GLOBAL
option when Apache loads the module with
the dlopen function (the Sun WorkShop docs
explicitly state that RTLD_GLOBAL must be
used in order for execptions to be handled
properly).  I have seen some traffic in
other forums regarding the "dlopen problem"
(e.g. LoadGlobalModule as a possible solution,
or hacking in "|RTLD_GLOBAL" in the call
to dlopen).  Does anyone know of any other
work arounds or if this issue will be
resolved in upcoming releases?

-----Original Message-----
From: Dean Gaudet <dgaudet@arctic.org>
To: new-httpd@apache.org <new-httpd@apache.org>
Date: Friday, July 10, 1998 10:19 AM
Subject: Re: RTLD_GLOBAL for DSO?


>If you do:
>
>#ifndef RTLD_GLOBAL
>#define RTLD_GLOBAL 0
>#endif
>
>Then I'm for it. 
>
>Dean
>
>On Fri, 10 Jul 1998, Rasmus Lerdorf wrote:
>
>> Would anybody object to the following patch?
>> 
>> +++ os.c        Fri Jul 10 13:12:17 1998
>> @@ -35,9 +35,9 @@
>>  #else
>>  #if defined(OSF1) ||\
>>      (defined(__FreeBSD_version) && (__FreeBSD_version >= 220000))
>> -    return dlopen((char *)path, RTLD_NOW);
>> +    return dlopen((char *)path, RTLD_NOW | RTLD_GLOBAL);
>>  #else
>> -    return dlopen(path, RTLD_NOW);
>> +    return dlopen(path, RTLD_NOW | RTLD_GLOBAL);
>>  #endif
>>  #endif
>>  }
>> 
>> Both mod_php3 and mod_perl would benefit from this since both are capable
>> of being loaded dynamically and in turn loading other things dynamically.
>> 
>> -Rasmus
>> 
>> 
>


Mime
View raw message