From: Luis de Bethencourt <luisbg@osg.samsung.com>
To: linux-kernel@vger.kernel.org
Cc: xfs@oss.sgi.com, david@fromorbit.com, bfoster@redhat.com,
sandeen@sandeen.net, namjae.jeon@samsung.com,
cmaiolino@redhat.com, darrick.wong@oracle.com,
billodo@redhat.com, Luis de Bethencourt <luisbg@osg.samsung.com>
Subject: [PATCH] xfs: remove impossible condition
Date: Thu, 25 Feb 2016 12:43:57 +0000 [thread overview]
Message-ID: <1456404237-18169-1-git-send-email-luisbg@osg.samsung.com> (raw)
bp_release is set to 0 just before the breakpoint of the for loop before
the conditional check (in line 458). The other breakpoint is a goto that
skips the dead code.
Addresses-Coverity-Id: 102338
Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com>
---
Hi,
Thanks for reviewing this :)
Luis
fs/xfs/libxfs/xfs_bmap.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/fs/xfs/libxfs/xfs_bmap.c b/fs/xfs/libxfs/xfs_bmap.c
index 6a05166..1171795 100644
--- a/fs/xfs/libxfs/xfs_bmap.c
+++ b/fs/xfs/libxfs/xfs_bmap.c
@@ -477,10 +477,7 @@ xfs_bmap_check_leaf_extents(
}
block = XFS_BUF_TO_BLOCK(bp);
}
- if (bp_release) {
- bp_release = 0;
- xfs_trans_brelse(NULL, bp);
- }
+
return;
error0:
--
2.5.1
next reply other threads:[~2016-02-25 12:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-25 12:43 Luis de Bethencourt [this message]
2016-03-01 12:08 ` [PATCH] xfs: remove impossible condition Christoph Hellwig
2016-03-01 13:23 ` Luis de Bethencourt
2016-03-01 18:22 ` Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1456404237-18169-1-git-send-email-luisbg@osg.samsung.com \
--to=luisbg@osg.samsung.com \
--cc=bfoster@redhat.com \
--cc=billodo@redhat.com \
--cc=cmaiolino@redhat.com \
--cc=darrick.wong@oracle.com \
--cc=david@fromorbit.com \
--cc=linux-kernel@vger.kernel.org \
--cc=namjae.jeon@samsung.com \
--cc=sandeen@sandeen.net \
--cc=xfs@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox