From ae266f893fd7b82680066c53b6d24ebf4353178b Mon Sep 17 00:00:00 2001 From: Enji Cooper Date: Mon, 19 Jan 2015 07:10:08 +0000 Subject: [PATCH] Fix the build when INVARIANTS is defined by restoring `bo`'s definition in ext2_truncate(..) and by putting it under INVARIANTS ifdefs X-MFC with: r277354 MFC after: 2 weeks --- sys/fs/ext2fs/ext2_inode.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/fs/ext2fs/ext2_inode.c b/sys/fs/ext2fs/ext2_inode.c index 2fc2192d05bd..36768fb1c418 100644 --- a/sys/fs/ext2fs/ext2_inode.c +++ b/sys/fs/ext2fs/ext2_inode.c @@ -121,8 +121,14 @@ ext2_truncate(struct vnode *vp, off_t length, int flags, struct ucred *cred, e4fs_daddr_t count, nblocks, blocksreleased = 0; int error, i, allerror; off_t osize; +#ifdef INVARIANTS + struct bufobj *bo; +#endif oip = VTOI(ovp); +#ifdef INVARIANTS + bo = &ovp->v_bufobj; +#endif ASSERT_VOP_LOCKED(vp, "ext2_truncate");