From 3a644063077a86899b59614048d84f86e77f75cd Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Thu, 22 Sep 2016 12:52:56 -0500 Subject: The notifying thread does not need to hold the lock on the same mutex as the one held by the waiting thread(s); in fact doing so is a pessimization. --- src/adbd-client.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/adbd-client.cpp b/src/adbd-client.cpp index 25aefa8..597e69f 100644 --- a/src/adbd-client.cpp +++ b/src/adbd-client.cpp @@ -131,7 +131,7 @@ g_debug("%s %s", G_STRLOC, G_STRFUNC); g_debug("%s %s", G_STRLOC, G_STRFUNC); // set m_pkresponse and wake up the waiting worker thread - std::lock_guard lk(m_pkresponse_mutex); + //std::lock_guard lk(m_pkresponse_mutex); //std::unique_lock lk(m_pkresponse_mutex); g_debug("%s %s", G_STRLOC, G_STRFUNC); m_pkresponse = response; -- cgit v1.2.3