Skip to content

Commit 3994688

Browse files
Dan Carpentersmfrench
authored andcommitted
cifs: potential unintitliazed error code in cifs_getattr()
Smatch complains that "rc" could be uninitialized. fs/cifs/inode.c:2206 cifs_getattr() error: uninitialized symbol 'rc'. Changing it to "return 0;" improves readability as well. Fixes: cc1baf9 ("cifs: do not ignore the SYNC flags in getattr") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Steve French <[email protected]> Acked-by: Ronnie Sahlberg <[email protected]>
1 parent fb33c65 commit 3994688

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/cifs/inode.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2191,7 +2191,7 @@ int cifs_getattr(const struct path *path, struct kstat *stat,
21912191
if (!(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_OVERR_GID))
21922192
stat->gid = current_fsgid();
21932193
}
2194-
return rc;
2194+
return 0;
21952195
}
21962196

21972197
int cifs_fiemap(struct inode *inode, struct fiemap_extent_info *fei, u64 start,

0 commit comments

Comments
 (0)