]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r351253:
authorDimitry Andric <dim@FreeBSD.org>
Tue, 3 Sep 2019 17:31:12 +0000 (17:31 +0000)
committerDimitry Andric <dim@FreeBSD.org>
Tue, 3 Sep 2019 17:31:12 +0000 (17:31 +0000)
commit4173b67f409166732ad30adf6ae107b8d3d65633
treee02d1d181c15548370138ea4d8c4d6db0d77ac91
parent03c884e13da8fe4abfc0b1cf3429dd0e11f852f2
MFC r351253:

Pull in r368867 from upstream libc++ trunk (by Marshall Clow):

  Rework recursive_timed_mutex so that it uses __thread_id instead of
  using the lower-level __libcpp_thread_id. This is prep for fixing
  PR42918. Reviewed as https://reviews.llvm.org/D65895

Pull in r368916 from upstream libc++ trunk (by Marshall Clow):

  Fix thread comparison by making sure we never pass our special 'not a
  thread' value to the underlying implementation. Fixes PR#42918.

This should fix std::thread::id::operator==() attempting to call
pthread_equal(3) with zero values.

Reported by: andrew@tao11.riddles.org.uk
PR: 239038, 239550
contrib/libc++/include/__threading_support
contrib/libc++/include/mutex
contrib/libc++/include/thread
contrib/libc++/src/mutex.cpp