lkml.org 
[lkml]   [2024]   [Feb]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH][next] bcachefs: remove redundant assignment to variable ret
Date
Variable ret is being assigned a value that is never read, it is
being re-assigned a couple of statements later on. The assignment
is redundant and can be removed.

Cleans up clang scan build warning:
fs/bcachefs/super-io.c:806:2: warning: Value stored to 'ret' is
never read [deadcode.DeadStores]

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
fs/bcachefs/super-io.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/fs/bcachefs/super-io.c b/fs/bcachefs/super-io.c
index 110dcb0337ce..c6d590404425 100644
--- a/fs/bcachefs/super-io.c
+++ b/fs/bcachefs/super-io.c
@@ -804,7 +804,6 @@ static int __bch2_read_super(const char *path, struct bch_opts *opts,
goto err;
}

- ret = 0;
sb->have_layout = true;

ret = bch2_sb_validate(sb, &err, READ);
--
2.39.2

\
 
 \ /
  Last update: 2024-05-27 15:14    [W:0.072 / U:1.256 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site