mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] staging: exfat: remove redundant goto
@ 2019-08-30 18:15 Colin King
  2019-08-31 10:30 ` Valdis Klētnieks
  0 siblings, 1 reply; 2+ messages in thread
From: Colin King @ 2019-08-30 18:15 UTC (permalink / raw)
  To: Valdis Kletnieks, Greg Kroah-Hartman, devel; +Cc: kernel-janitors, linux-kernel

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

The goto after a return is never executed, so it is redundant and can
be removed.

Addresses-Coverity: ("Structurally dead code")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 drivers/staging/exfat/exfat_super.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/staging/exfat/exfat_super.c b/drivers/staging/exfat/exfat_super.c
index 5b5c2ca8c9aa..5b3c4dfe0ecc 100644
--- a/drivers/staging/exfat/exfat_super.c
+++ b/drivers/staging/exfat/exfat_super.c
@@ -663,10 +663,8 @@ static int ffsLookupFile(struct inode *inode, char *path, struct file_id_t *fid)
 	/* search the file name for directories */
 	dentry = p_fs->fs_func->find_dir_entry(sb, &dir, &uni_name, num_entries,
 					       &dos_name, TYPE_ALL);
-	if (dentry < -1) {
+	if (dentry < -1)
 		return FFS_NOTFOUND;
-		goto out;
-	}
 
 	fid->dir.dir = dir.dir;
 	fid->dir.size = dir.size;
-- 
2.20.1


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

end of thread, other threads:[~2019-08-31 10:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-30 18:15 [PATCH] staging: exfat: remove redundant goto Colin King
2019-08-31 10:30 ` Valdis Klētnieks

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

all inboxes | Powered by JetHome®