/* stdlib */
_Exit
-__atexit
-__atexit_register_cleanup
__cxa_atexit
__cxa_finalize
__isthreaded
-/* $OpenBSD: stdlib.h,v 1.4 2015/09/19 04:02:21 guenther Exp $ */
+/* $OpenBSD: stdlib.h,v 1.5 2015/10/25 18:01:24 guenther Exp $ */
/* $NetBSD: stdlib.h,v 1.25 1995/12/27 21:19:08 jtc Exp $ */
/*-
__BEGIN_HIDDEN_DECLS
char *__findenv(const char *, int, int *);
+void __atexit_register_cleanup(void (*)(void));
__END_HIDDEN_DECLS
#if 0
-/* $OpenBSD: local.h,v 1.22 2015/10/04 07:33:46 guenther Exp $ */
+/* $OpenBSD: local.h,v 1.23 2015/10/25 18:01:24 guenther Exp $ */
/*-
* Copyright (c) 1990, 1993
int _fwalk(int (*)(FILE *));
PROTO_NORMAL(_fwalk);
-extern void __atexit_register_cleanup(void (*)(void));
-
__BEGIN_HIDDEN_DECLS
int __sflush(FILE *);
int __sflush_locked(FILE *);
-/* $OpenBSD: atexit.c,v 1.21 2015/04/07 01:27:07 guenther Exp $ */
+/* $OpenBSD: atexit.c,v 1.22 2015/10/25 18:01:24 guenther Exp $ */
/*
* Copyright (c) 2002 Daniel Hartmeier
* All rights reserved.
_ATEXIT_UNLOCK();
return (ret);
}
+DEF_STRONG(__cxa_atexit);
/*
* Call all handlers registered with __cxa_atexit() for the shared
}
}
+DEF_STRONG(__cxa_finalize);
/*
* Register the cleanup function
-/* $OpenBSD: atexit.h,v 1.9 2014/06/18 19:01:10 kettenis Exp $ */
+/* $OpenBSD: atexit.h,v 1.10 2015/10/25 18:01:24 guenther Exp $ */
/*
* Copyright (c) 2002 Daniel Hartmeier
} fns[1]; /* the table itself */
};
+__BEGIN_HIDDEN_DECLS
extern struct atexit *__atexit; /* points to head of LIFO stack */
+__END_HIDDEN_DECLS
int __cxa_atexit(void (*)(void *), void *, void *);
void __cxa_finalize(void *);
+
+PROTO_NORMAL(__cxa_atexit);
+PROTO_NORMAL(__cxa_finalize);
-# $OpenBSD: Makefile,v 1.5 2003/07/31 22:46:59 david Exp $
+# $OpenBSD: Makefile,v 1.6 2015/10/25 18:01:24 guenther Exp $
NOMAN=
PROG=atexit_test
-CPPFLAGS+=-I${.CURDIR}/../../../../lib/libc
+CPPFLAGS+=-I${.CURDIR}/../../../../lib/libc -D'PROTO_NORMAL(x)=__asm("")'
CLEANFILES+= invalid.out valid.out
+LDADD=-static
run-regress-atexit_test: ${PROG}
./${PROG} -valid 2>${.OBJDIR}/valid.out