projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e17b93e
)
bcachefs: Fix redundant variable initialization
author
Kent Overstreet
<kent.overstreet@linux.dev>
Sat, 11 Nov 2023 21:02:15 +0000
(16:02 -0500)
committer
Kent Overstreet
<kent.overstreet@linux.dev>
Mon, 1 Jan 2024 16:47:37 +0000
(11:47 -0500)
path->level was being read, but never used.
Reported-by: Colin Ian King <colin.i.king@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/btree_iter.c
patch
|
blob
|
history
diff --git
a/fs/bcachefs/btree_iter.c
b/fs/bcachefs/btree_iter.c
index da594e0067697c49eb053fccb522dba8f6cc3b99..bf4d2ade45355c7a03eda9b83735ff798a5c4ca6 100644
(file)
--- a/
fs/bcachefs/btree_iter.c
+++ b/
fs/bcachefs/btree_iter.c
@@
-1214,8
+1214,6
@@
__bch2_btree_path_set_pos(struct btree_trans *trans,
struct btree_path *path, struct bpos new_pos,
bool intent, unsigned long ip, int cmp)
{
- unsigned level = path->level;
-
bch2_trans_verify_not_in_restart(trans);
EBUG_ON(!path->ref);
@@
-1231,7
+1229,7
@@
__bch2_btree_path_set_pos(struct btree_trans *trans,
goto out;
}
- level = btree_path_up_until_good_node(trans, path, cmp);
+
unsigned
level = btree_path_up_until_good_node(trans, path, cmp);
if (btree_path_node(path, level)) {
struct btree_path_level *l = &path->l[level];