Fix bracing in ASSERT_VP_ISLOCKED(vp) macro to not always panic()
authorguenther <guenther@openbsd.org>
Mon, 19 Jan 2015 20:13:03 +0000 (20:13 +0000)
committerguenther <guenther@openbsd.org>
Mon, 19 Jan 2015 20:13:03 +0000 (20:13 +0000)
From Helg (xx404 (at) msn.com)

sys/kern/vfs_vops.c

index f7ec9a5..fa23ace 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: vfs_vops.c,v 1.9 2013/08/13 05:52:24 guenther Exp $   */
+/*     $OpenBSD: vfs_vops.c,v 1.10 2015/01/19 20:13:03 guenther Exp $  */
 /*
  * Copyright (c) 2010 Thordur I. Bjornsson <thib@openbsd.org> 
  *
 #include <sys/unistd.h>
 
 #ifdef VFSLCKDEBUG
-#define ASSERT_VP_ISLOCKED(vp) do {                             \
-        if (((vp)->v_flag & VLOCKSWORK) && !VOP_ISLOCKED(vp))   \
-                VOP_PRINT(vp);                                  \
-                panic("vp not locked");                         \
+#define ASSERT_VP_ISLOCKED(vp) do {                            \
+       if (((vp)->v_flag & VLOCKSWORK) && !VOP_ISLOCKED(vp)) { \
+               VOP_PRINT(vp);                                  \
+               panic("vp not locked");                         \
+       }                                                       \
 } while (0)
 #else
 #define ASSERT_VP_ISLOCKED(vp)  /* nothing */