From 922247e25bfb64bdbe43dd8133881aaf405b8a0b Mon Sep 17 00:00:00 2001 From: Boris Ranto Date: Mon, 8 Dec 2014 08:36:37 +0100 Subject: [PATCH] Backport pull request #2937 to firefly --- src/common/RWLock.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/common/RWLock.h b/src/common/RWLock.h index f901ac0..4699b66 100644 --- a/src/common/RWLock.h +++ b/src/common/RWLock.h @@ -36,7 +36,9 @@ public: } virtual ~RWLock() { - pthread_rwlock_unlock(&L); + // The following check is racy but we are about to destroy + // the object and we assume that there are no other users. + //assert(!is_locked()); -- hacky backport, no is_locked in firefly pthread_rwlock_destroy(&L); } -- 2.1.3