public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH][next] xfs: remove redundant assignment to variable error
@ 2019-11-06 15:52 Colin King
  2019-11-06 15:56 ` Darrick J. Wong
  0 siblings, 1 reply; 7+ messages in thread
From: Colin King @ 2019-11-06 15:52 UTC (permalink / raw)
  To: Darrick J . Wong, linux-xfs; +Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Variable error is being initialized with a value that is never read
and is being re-assigned a couple of statements later on. The
assignment is redundant and hence can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 fs/xfs/xfs_super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index b3188ea49413..2302f67d1a18 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs/xfs_super.c
@@ -1362,7 +1362,7 @@ xfs_fc_fill_super(
 {
 	struct xfs_mount	*mp = sb->s_fs_info;
 	struct inode		*root;
-	int			flags = 0, error = -ENOMEM;
+	int			flags = 0, error;
 
 	mp->m_super = sb;
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-11-07  6:44 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-11-06 15:52 [PATCH][next] xfs: remove redundant assignment to variable error Colin King
2019-11-06 15:56 ` Darrick J. Wong
2019-11-06 15:59   ` Colin Ian King
2019-11-06 16:19     ` Eric Sandeen
2019-11-06 16:33       ` Colin Ian King
2019-11-06 16:53         ` Eric Sandeen
2019-11-07  6:44       ` Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox