Module Name: src Committed By: dholland Date: Thu Jul 10 06:02:40 UTC 2014
Modified Files: src/sys/ufs/ffs: ffs_snapshot.c Log Message: Use an explicit compare to 0 for an immediate error result, not !. Using ! is perfectly clear on variables like "error" or "result", but directly on a function call it tends to look like a mistake. To generate a diff of this commit: cvs rdiff -u -r1.135 -r1.136 src/sys/ufs/ffs/ffs_snapshot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/ufs/ffs/ffs_snapshot.c diff -u src/sys/ufs/ffs/ffs_snapshot.c:1.135 src/sys/ufs/ffs/ffs_snapshot.c:1.136 --- src/sys/ufs/ffs/ffs_snapshot.c:1.135 Fri May 30 08:40:09 2014 +++ src/sys/ufs/ffs/ffs_snapshot.c Thu Jul 10 06:02:40 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: ffs_snapshot.c,v 1.135 2014/05/30 08:40:09 hannken Exp $ */ +/* $NetBSD: ffs_snapshot.c,v 1.136 2014/07/10 06:02:40 dholland Exp $ */ /* * Copyright 2000 Marshall Kirk McKusick. All Rights Reserved. @@ -38,7 +38,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ffs_snapshot.c,v 1.135 2014/05/30 08:40:09 hannken Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ffs_snapshot.c,v 1.136 2014/07/10 06:02:40 dholland Exp $"); #if defined(_KERNEL_OPT) #include "opt_ffs.h" @@ -399,7 +399,7 @@ out: #endif } if (error) { - if (!UFS_WAPBL_BEGIN(mp)) { + if (UFS_WAPBL_BEGIN(mp) == 0) { (void) ffs_truncate(vp, (off_t)0, 0, NOCRED); UFS_WAPBL_END(mp); }