From 5ae48b06e156b4c8e83d4888f982f038232c044f Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Thu, 29 Nov 2018 06:22:39 -0800 Subject: [PATCH] Fix the pthread_detach assert on Darwin. --- lib/execute/signalhandlers/SignalHandlers.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/execute/signalhandlers/SignalHandlers.cpp b/lib/execute/signalhandlers/SignalHandlers.cpp index 71ba9c3a02..f47d7ec7f9 100644 --- a/lib/execute/signalhandlers/SignalHandlers.cpp +++ b/lib/execute/signalhandlers/SignalHandlers.cpp @@ -772,7 +772,7 @@ EnsureDarwinMachPorts() return false; } r = pthread_detach(handlerThread); - assert(r != 0); + assert(r == 0); // In addition to the process-wide signal handler setup, OSX needs each // thread configured to send its exceptions to sMachDebugPort. While there