aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/sync.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/sync.h b/src/sync.h
index a4c22f67cc..43473534db 100644
--- a/src/sync.h
+++ b/src/sync.h
@@ -311,6 +311,9 @@ struct SCOPED_LOCKABLE LockAnnotation
template <typename Mutex>
explicit LockAnnotation(Mutex& mutex) EXCLUSIVE_LOCK_FUNCTION(mutex)
{
+#ifdef DEBUG_LOCKORDER
+ AssertLockHeld(mutex);
+#endif
}
~LockAnnotation() UNLOCK_FUNCTION() {}
};