summaryrefslogtreecommitdiff
path: root/src/lib/libc/stdlib/atexit.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Move __cxa_thread_atexit* to its own .c file to avoid pulling the codeguenther2017-12-161-1/+8
| | | | | | | (w/ _dlctl reference) into static executables. It's all Mark's code so put his preferred copyright on it. ok kettenis@
* Implement __cxa_thread_atexit to support C++11 thread_local scope. Thekettenis2017-12-051-1/+3
| | | | | | | interface is also made available as __cxa_thread_atexit_impl to satisfy the needs of GNU libstdc++. ok guenther@, millert@
* Hide __atexit and __atexit_register_cleanup()guenther2015-10-251-1/+6
| | | | | | | | Wrap __cxa_{atexit,finalize}() so the call from exit() goes direct Switch regress/lib/libc/atexit/ to be built with -static so that it can still access __atexit* ok millert@ jca@
* Always call atexit handlers as if they were registered with __cxa_atexit.kettenis2014-06-181-5/+2
| | | | | | | | | | | The extra argument doesn't hurt genuine atexit handlers and this fixes a bug where we didn't provide the argument (effectively passing garbage) for functions registered with __cxa_atexit in the main executable. Pointed out by Dmitriy Ivanov <dimitry@google.com> and Elliott Hughes <enh@google.com>. ok matthew@
* Two small cleanups to atexit: remove unneeded __atexit_invalid, andmatthew2013-06-021-2/+1
| | | | | | | move the call_depth decrement so it happens unconditionally and can still return to 0 when called with dso!=NULL. ok millert
* Add __cxa_atexit() support for gcc3. This provides support for shared ↵millert2007-09-031-2/+12
| | | | object destructors called at dlclose() time. Inspired by similar changes in FreeBSD and NetBSD.
* fix a protoderaadt2003-07-311-2/+2
|
* re-enable function pointer table protection, this time make sure thatdhartmei2002-08-301-30/+26
| | | | | malloc.c gets the first mmap() call (since it depends on that, for its sbrk(0) use). ok deraadt@
* Back it out, it breaks something in perl (seen with spamassassin), debugdhartmei2002-07-311-26/+30
| | | | first.
* Replace atexit handler. mprotect() the pages so an attempt to modify thedhartmei2002-07-291-30/+26
| | | | | function pointers from the outside will segfault. Idea, hints and feedback from deraadt. ok deraadt.
* Fix RCS idstholo1996-08-191-2/+1
| | | | Make sure everything uses {SYS,}LIBC_SCCS properly
* initial import of NetBSD treederaadt1995-10-181-0/+46