From cc0f33fe0aa00181bc5936e51f04e1f36d5db802 Mon Sep 17 00:00:00 2001 From: David Xu Date: Sat, 23 Dec 2006 00:59:50 +0000 Subject: MFR6: return EINVAL if thread was detached. Approved by: re (kensmith) --- lib/libthr/thread/thr_join.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/libthr') diff --git a/lib/libthr/thread/thr_join.c b/lib/libthr/thread/thr_join.c index 5b70391b4abd..26c2c325d406 100644 --- a/lib/libthr/thread/thr_join.c +++ b/lib/libthr/thread/thr_join.c @@ -84,7 +84,7 @@ join_common(pthread_t pthread, void **thread_return, if ((ret = _thr_find_thread(curthread, pthread, 1)) != 0) { ret = ESRCH; } else if ((pthread->tlflags & TLFLAGS_DETACHED) != 0) { - ret = ESRCH; + ret = EINVAL; } else if (pthread->joiner != NULL) { /* Multiple joiners are not supported. */ ret = ENOTSUP; -- cgit v1.3