ovs-thread: Fix OVS_ADAPTIVE_MUTEX_INITIALIZER.
authorBen Pfaff <blp@nicira.com>
Thu, 1 May 2014 15:46:45 +0000 (08:46 -0700)
committerBen Pfaff <blp@nicira.com>
Thu, 1 May 2014 15:46:45 +0000 (08:46 -0700)
Commit 05bf6d3c62e1d (ovs-thread: Add checking for mutex and rwlock
initialization.) updated mutex and rwlock initializers to set the "where"
member to a nonnull value, but missed this one.  This commit fixes the
problem.

This does not cause real problems in practice because
OVS_ADAPTIVE_MUTEX_INITIALIZER has no existing users.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
lib/ovs-thread.h

index 180b66f..68db71f 100644 (file)
@@ -40,7 +40,7 @@ struct OVS_LOCKABLE ovs_mutex {
 
 #ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP
 #define OVS_ADAPTIVE_MUTEX_INITIALIZER                  \
-    { PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP, NULL }
+    { PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP, "<unlocked>" }
 #else
 #define OVS_ADAPTIVE_MUTEX_INITIALIZER OVS_MUTEX_INITIALIZER
 #endif