diff options
Diffstat (limited to 'lib/libc/stdlib/exit.c')
-rw-r--r-- | lib/libc/stdlib/exit.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/libc/stdlib/exit.c b/lib/libc/stdlib/exit.c index e358c94fd66..bc7fd395ca3 100644 --- a/lib/libc/stdlib/exit.c +++ b/lib/libc/stdlib/exit.c @@ -32,7 +32,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char *rcsid = "$OpenBSD: exit.c,v 1.2 1996/08/19 08:33:30 tholo Exp $"; +static char *rcsid = "$OpenBSD: exit.c,v 1.3 1998/11/20 11:18:50 d Exp $"; #endif /* LIBC_SCCS and not lint */ #include <stdlib.h> @@ -42,6 +42,15 @@ static char *rcsid = "$OpenBSD: exit.c,v 1.2 1996/08/19 08:33:30 tholo Exp $"; void (*__cleanup)(); /* + * This variable is zero until a process has created a thread. + * It is used to avoid calling locking functions in libc when they + * are not required. By default, libc is intended to be(come) + * thread-safe, but without a (significant) penalty to non-threaded + * processes. + */ +int __isthreaded = 0; + +/* * Exit, flushing stdio buffers if necessary. */ void |