Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-6-0]: src/lib/libpthread Pull up following revision(s) (requested...
details: https://anonhg.NetBSD.org/src/rev/f629c1012603
branches: netbsd-6-0
changeset: 774868:f629c1012603
user: riz <riz%NetBSD.org@localhost>
date: Thu Sep 26 02:02:07 2013 +0000
description:
Pull up following revision(s) (requested by riastradh in ticket #959):
lib/libpthread/pthread.c: revision 1.137
return errno if pthread_create hits the system limit, not just -1
(this is not entirely correct because it can return ENOMEM which is
not mentioned in the spec, but there are other places in pthread_create
whete ENOMEM is returned -- it at all, this should be fixed everywhere)
diffstat:
lib/libpthread/pthread.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diffs (26 lines):
diff -r 03a251976265 -r f629c1012603 lib/libpthread/pthread.c
--- a/lib/libpthread/pthread.c Thu Sep 26 01:56:27 2013 +0000
+++ b/lib/libpthread/pthread.c Thu Sep 26 02:02:07 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pthread.c,v 1.125.4.1 2012/05/07 03:12:33 riz Exp $ */
+/* $NetBSD: pthread.c,v 1.125.4.1.4.1 2013/09/26 02:02:07 riz Exp $ */
/*-
* Copyright (c) 2001, 2002, 2003, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: pthread.c,v 1.125.4.1 2012/05/07 03:12:33 riz Exp $");
+__RCSID("$NetBSD: pthread.c,v 1.125.4.1.4.1 2013/09/26 02:02:07 riz Exp $");
#define __EXPOSE_STACK 1
@@ -433,6 +433,7 @@
flag |= LWP_SUSPENDED;
ret = _lwp_create(&newthread->pt_uc, flag, &newthread->pt_lid);
if (ret != 0) {
+ ret = errno;
pthread_mutex_lock(&newthread->pt_lock);
/* Will unlock and free name. */
pthread__reap(newthread);
Home |
Main Index |
Thread Index |
Old Index