From: amartin@denton.zko.dec.com (Alan H. Martin)
Subject: Re: dlopen/dlclose & C++ (DEC UNIX)
Date: 1996/03/27 [thread overview]
Message-ID: <4jbk1u$ko7@zk2nws.zko.dec.com> (raw)
In-Reply-To: 4j6q8e$ucf@xensei3.xensei.com
In article <4j6q8e$ucf@xensei3.xensei.com> ccrlphr@xensei.com writes:
>I got a problem while using the dynamic loading with C++ (DEC CXX 5.0).
>I wrote a app which defines an interface == class within a header file
>and lets you dynamically load libraries with this interface within the
>run of the prog, e.g.:
Cool.
>... My problem starts if I don't need the lib any longer and want to get the
>memory back using <dlclose>. ...
The file /usr/lib/cmplrs/cxx/DECCXX500.release-notes states on pp. 1-10 and
1-11:
"
1.3.3 Current Restrictions
This section contains usage notes and known problems with
DEC C++ Version 5.0.
...
o Static destructors in dynamically loaded DEC C++ shared
libraries are not invoked if the DEC OSF/1 Alpha library
routine dlclose(3) is used to dynamically unload the C++
shared libraries. Furthermore, the main program fails
when exiting because it attempts to call the destructors
in the unloaded shared libraries.
"
Sorry about that.
>This generates the question if this is
> a) a general problem between C++ and the dl-library
> b) a problem between DEC CXX (V5.0) and the dl-library
> c) a problem on DEC UNIX (osf/1 V.3.2C)
> d) a problem of misusage
> e) nothing of the above
It's a day-one design flaw in the C++ runtime support code which executes
static object destructors upon program exit (and dlclose).
The problem is fixed in DEC C++/Alpha/Unix V5.3, scheduled to ship on CDrom on
12-Apr-96.
>BTW, does anybody knows a workaround ?? (except "not calling <dlopen>")
Will disabling the dlclose calls for a few more weeks suffice?
/AHM/THX
--
Alan Howard Martin AMartin@TLE.ENet.DEC.Com
prev parent reply other threads:[~1996-03-27 5:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-03-25 5:00 dlopen/dlclose & C++ (DEC UNIX) ccrlphr
1996-03-27 5:00 ` Alan H. Martin [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox