mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
BACKPORT: cifs: fix SMB1 error path in cifs_get_file_info_unix
We were trying to fill in uninitialized file attributes in the error case.
Addresses-Coverity: 139689 ("Uninitialized variables")
Signed-off-by: Steve French <stfrench@microsoft.com>
(cherry picked from commit e39df24169)
Change-Id: Id02f0a50c2ba3505bb8f5538f489e451c9423c0b
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
This commit is contained in:
@@ -360,9 +360,12 @@ cifs_get_file_info_unix(struct file *filp)
|
||||
} else if (rc == -EREMOTE) {
|
||||
cifs_create_dfs_fattr(&fattr, inode->i_sb);
|
||||
rc = 0;
|
||||
}
|
||||
} else
|
||||
goto cifs_gfiunix_out;
|
||||
|
||||
cifs_fattr_to_inode(inode, &fattr);
|
||||
|
||||
cifs_gfiunix_out:
|
||||
free_xid(xid);
|
||||
return rc;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user