]> git.baikalelectronics.ru Git - kernel.git/commit
cifs: potential unintitliazed error code in cifs_getattr()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 28 Feb 2020 09:22:59 +0000 (12:22 +0300)
committerSteve French <stfrench@microsoft.com>
Tue, 17 Mar 2020 18:26:26 +0000 (13:26 -0500)
commitf3168a52acd9c55d92a5d370c76ee65741cc0c8a
treef668cd4abd909f616b731eb6553a1524714ba432
parent300f50a3847de83aa4b2e44fa28dd668de331982
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: cc1baf98c8f6 ("cifs: do not ignore the SYNC flags in getattr")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Acked-by: Ronnie Sahlberg <lsahlber@redhat.com>
fs/cifs/inode.c