Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 04 Feb 2001 11:54:43 -0500
From:      Brian McGovern <mcgovern@spoon.beta.com>
To:        hackers@freebsd.org
Subject:   exit() does not do dlclose()?
Message-ID:  <200102041654.f14Gsh808001@spoon.beta.com>

next in thread | raw e-mail | index | archive | help
I'm playing with an application that uses dlopen() to load some libraries. I
use the _init function to set the libraries up. I've also set up the _fini
functions to shut things down.

I see, in the man page, that dlclose() will unload the libraries and call
_fini.

My question is whether or not exit() does the same thing? It currently does
not appear to, although that would seem rather odd to me, given the other
types of cleanup it does.

Is this due to the fact that dlopen() bypasses the 'normal' loader, and 
therefore the cleanup routines can not understand how to get rid of them
correctly?

	-Brian


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200102041654.f14Gsh808001>