From 76f5c973ba61270aa63824ade2acdfbe8101bd8c Mon Sep 17 00:00:00 2001 From: Rachita Kothiyal Date: Fri, 29 Feb 2008 12:03:39 -0500 Subject: [PATCH] Unionfs: improve debugging in copy_attr_times Signed-off-by: Erez Zadok --- fs/unionfs/subr.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/fs/unionfs/subr.c b/fs/unionfs/subr.c index f68624d76e..167eac9d7f 100644 --- a/fs/unionfs/subr.c +++ b/fs/unionfs/subr.c @@ -88,8 +88,14 @@ void unionfs_copy_attr_times(struct inode *upper) int bindex; struct inode *lower; - if (!upper || ibstart(upper) < 0) + if (!upper) return; + if (ibstart(upper) < 0) { +#ifdef CONFIG_UNION_FS_DEBUG + WARN_ON(ibstart(upper) < 0); +#endif /* CONFIG_UNION_FS_DEBUG */ + return; + } for (bindex = ibstart(upper); bindex <= ibend(upper); bindex++) { lower = unionfs_lower_inode_idx(upper, bindex); if (!lower) -- 2.43.0