Skip to contentSkip to conversation

fs: remove redundant assignment to variable ret

PATCH New Colin King 1 participant 1 message May 12, 2020

Subsystems (2)
lore
Share & tools
lore

Colin King

author
#0 lore raw

PATCH 1/1 fs: remove redundant assignment to variable ret

From: Colin Ian King <[email protected]>

The variable ret is being assigned a value that is never read and it is being updated later with a new value. The assignment is redundant and can be removed.

Addresses-Coverity: ("Unused value")

---
 fs/super.c | 1 -
 1 file changed, 1 deletion(-)
fs/super.c +0 -1
index b0a511bef4a0..6674c2af26ef 100644
@@ -2052,7 +2052,6 @@ SYSCALL_DEFINE5(watch_sb,
 		if (drop_s_count)
 			put_super(s);
 	} else {
-		ret = -EBADSLT;
 		down_write(&s->s_umount);
 		ret = remove_watch_from_object(s->s_watchers, wqueue,
 					       s->s_unique_id, false);
Signature · 1 line
2.25.1