diff options
author | David Chisnall <theraven@theravensnest.org> | 2012-02-28 19:20:58 +0000 |
---|---|---|
committer | David Chisnall <theraven@theravensnest.org> | 2012-02-28 19:20:58 +0000 |
commit | b9c89de0416513998e06bf23115191717416a416 (patch) | |
tree | ba3a0302e9f21c13f49c3443d00e3e84d5daa1fa /src/cxa_finalize.c | |
parent | 69c4c6f192271918d1bf64a84d3f8a41d1e943ac (diff) | |
download | libcxxrt-b9c89de0416513998e06bf23115191717416a416.tar.gz libcxxrt-b9c89de0416513998e06bf23115191717416a416.tar.bz2 libcxxrt-b9c89de0416513998e06bf23115191717416a416.tar.xz |
Add some stuff that's missing on Solaris (required for correctly running
static destructors).
Diffstat (limited to 'src/cxa_finalize.c')
-rw-r--r-- | src/cxa_finalize.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/cxa_finalize.c b/src/cxa_finalize.c new file mode 100644 index 0000000..c870ca8 --- /dev/null +++ b/src/cxa_finalize.c @@ -0,0 +1,8 @@ +void __cxa_finalize(void *d ); + +extern void __dso_handle; + +__attribute((destructor)) +static void cleanup(void) { + __cxa_finalize(&__dso_handle); +} |