Ask a Question related to UNIX Programming, Design and Development.
-
Gianni Mariani #1
Re: load lib
Adv wrote:
dlclose() will unmap the library from the process.> Hi,
> I get aborted when dlclose() on a gnu/linux box and my code runs as a
> multithreaded server, so, is dlclose()/dl...() thread-safe? if not, how
> about elf's auto load? the loaded lib is/isn't thread safe will not be issue
> here?
Hence, if you are still needing it (perhaps a return address on the
stack or a virtual destructor or whatever) it will SEGV.
dlopen/dlclose is probably not thread safe (since it needs to run before
a thread library is available) but that's an easy fix to wrap them in
a mutex.
Gianni Mariani Guest
-
How can I load load Additional extensions ?
My OS is Winxp . My web server is apache 2 which is installed as a NT service . My php version is 4.32 , and I extracted it into "c:\php" . I... -
my swf doesn't load
Dnia Fri, 13 Aug 2004 10:16:47 GMT, decorix <decorix@hotmail.com> napisał: My english is poor :) Some serv change filenames (for example:... -
I want to load a swf from another swf?
I want to build a preloader in a movie that loads another hidden movie. After the hidden movie is loaded it become visible and the preloader... -
my .swf won't load
Do you have a limit on your file sizes for that site? Your 6 meg file is there.. Portfolio.swf, but there is another file with lower case p..... -
load of ram
Hi, for a long time we want to detect what is the ram load. Now my question: Is there an easy way, to get the information for the size of a... -
DL #2
Re: load lib
There are two things, first, I have used some mutexes and I don't want to
make things more complicated for me :), second, auto loading will not have
such an issue, will it?
?
How about keep the "handle" (via dlopen()) visible globally, and call
ldsym() without a mutex involoved in each thread?
"Gianni Mariani" <gi2nospam@mariani.ws> wrote in message
news:bf2unu$35b@dispatch.concentric.net...issue> Adv wrote:> > Hi,
> > I get aborted when dlclose() on a gnu/linux box and my code runs as a
> > multithreaded server, so, is dlclose()/dl...() thread-safe? if not, how
> > about elf's auto load? the loaded lib is/isn't thread safe will not be>> > here?
> dlclose() will unmap the library from the process.
>
> Hence, if you are still needing it (perhaps a return address on the
> stack or a virtual destructor or whatever) it will SEGV.
>
> dlopen/dlclose is probably not thread safe (since it needs to run before
> a thread library is available) but that's an easy fix to wrap them in
> a mutex.
>
>
DL Guest
-
Valentin Nechayev #3
Re: load lib
>>> Gianni Mariani wrote:
GM> dlopen/dlclose is probably not thread safe (since it needs to run before
GM> a thread library is available) but that's an easy fix to wrap them in
GM> a mutex.
1. Thread library can be loaded not only by dlopen(), but by runtime
loader (rtld), such as (/lib|/usr/lib|/usr/libexec)/(ld.so|ld-elf.so|...)
2. There are issues except simple serialization of accessing dl*() internal
structures; see recent history of FreeBSD rtld.
3. Even if function is made thread-safe with explicit serialization, it
can be used without threading library; again, see FreeBSD implementation
for malloc().
-netch-
Valentin Nechayev Guest



Reply With Quote

