mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 12:43:29 +02:00
cifs: return proper error code in statfs(2)
In cifs_statfs(), if server->ops->queryfs is not NULL, then we should use its return value rather than always returning 0. Instead, use rc variable as it is properly set to 0 in case there is no server->ops->queryfs. Signed-off-by: Paulo Alcantara (SUSE) <pc@cjr.nz> Reviewed-by: Aurelien Aptel <aaptel@suse.com> Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com> CC: <stable@vger.kernel.org> Signed-off-by: Steve French <stfrench@microsoft.com>
This commit is contained in:
committed by
Steve French
parent
e3d100eae4
commit
14302ee330
@@ -290,7 +290,7 @@ cifs_statfs(struct dentry *dentry, struct kstatfs *buf)
|
|||||||
rc = server->ops->queryfs(xid, tcon, cifs_sb, buf);
|
rc = server->ops->queryfs(xid, tcon, cifs_sb, buf);
|
||||||
|
|
||||||
free_xid(xid);
|
free_xid(xid);
|
||||||
return 0;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
static long cifs_fallocate(struct file *file, int mode, loff_t off, loff_t len)
|
static long cifs_fallocate(struct file *file, int mode, loff_t off, loff_t len)
|
||||||
|
Reference in New Issue
Block a user