diff options
| author | ad <ad@NetBSD.org> | 2007-12-07 20:36:52 +0000 |
|---|---|---|
| committer | ad <ad@NetBSD.org> | 2007-12-07 20:36:52 +0000 |
| commit | 37132d5d2fea8092896ddda7c8946f501c23f63e (patch) | |
| tree | 1254c491a54db0eae01581b8a644650ff2ae1f28 /lib/libpthread/pthread_specific.c | |
| parent | 558a5ffd0ff9eb1a1ff824e047823bf8d361dac1 (diff) | |
Back out previous now that libc/libpthread are initialized first.
Diffstat (limited to 'lib/libpthread/pthread_specific.c')
| -rw-r--r-- | lib/libpthread/pthread_specific.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/lib/libpthread/pthread_specific.c b/lib/libpthread/pthread_specific.c index 9d39d72fbac..6596bee74c2 100644 --- a/lib/libpthread/pthread_specific.c +++ b/lib/libpthread/pthread_specific.c @@ -1,4 +1,4 @@ -/* $NetBSD: pthread_specific.c,v 1.14 2007/12/01 01:19:31 ad Exp $ */ +/* $NetBSD: pthread_specific.c,v 1.15 2007/12/07 20:36:52 ad Exp $ */ /*- * Copyright (c) 2001, 2007 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: pthread_specific.c,v 1.14 2007/12/01 01:19:31 ad Exp $"); +__RCSID("$NetBSD: pthread_specific.c,v 1.15 2007/12/07 20:36:52 ad Exp $"); /* Functions and structures dealing with thread-specific data */ @@ -79,8 +79,5 @@ pthread_getspecific(pthread_key_t key) unsigned int pthread_curcpu_np(void) { - lwpctl_t *lc = pthread__self()->pt_lwpctl; - if (lc == NULL) - return 0; - return lc->lc_curcpu; + return pthread__self()->pt_lwpctl->lc_curcpu; } |
