Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 7 May 2017 07:55:58 +0000 (UTC)
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r317897 - stable/11/lib/libc/gen
Message-ID:  <201705070755.v477twrQ017522@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kib
Date: Sun May  7 07:55:58 2017
New Revision: 317897
URL: https://svnweb.freebsd.org/changeset/base/317897

Log:
  MFC r317611:
  Make semaphore names list mutex non-recursive.

Modified:
  stable/11/lib/libc/gen/sem_new.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/lib/libc/gen/sem_new.c
==============================================================================
--- stable/11/lib/libc/gen/sem_new.c	Sun May  7 07:54:21 2017	(r317896)
+++ stable/11/lib/libc/gen/sem_new.c	Sun May  7 07:55:58 2017	(r317897)
@@ -104,12 +104,8 @@ sem_child_postfork(void)
 static void
 sem_module_init(void)
 {
-	pthread_mutexattr_t ma;
 
-	_pthread_mutexattr_init(&ma);
-	_pthread_mutexattr_settype(&ma,  PTHREAD_MUTEX_RECURSIVE);
-	_pthread_mutex_init(&sem_llock, &ma);
-	_pthread_mutexattr_destroy(&ma);
+	_pthread_mutex_init(&sem_llock, NULL);
 	_pthread_atfork(sem_prefork, sem_postfork, sem_child_postfork);
 }
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201705070755.v477twrQ017522>