From 34505cb376f7430f2b6f1a9642089035e544fc34 Mon Sep 17 00:00:00 2001 From: Kirk McKusick Date: Tue, 27 Feb 2007 07:34:28 +0000 Subject: [PATCH] KASSERT fails when the condition is false, not when it is true. --- sys/sys/extattr.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/extattr.h b/sys/sys/extattr.h index b531e7ee6e2c..ece538582b40 100644 --- a/sys/sys/extattr.h +++ b/sys/sys/extattr.h @@ -112,7 +112,7 @@ int extattr_check_cred(struct vnode *vp, int attrnamespace, /* User-level definition of KASSERT for macros above */ #define KASSERT(cond, str) do { \ - if (cond) { printf("panic: "); printf(str); printf("\n"); exit(1); } \ + if (!(cond)) { printf("panic: "); printf(str); printf("\n"); exit(1); }\ } while (0) struct iovec;