OSDN Git Service

cifs: fix file info setting in cifs_query_path_info()
authorPaulo Alcantara <pc@cjr.nz>
Fri, 6 Jan 2023 23:28:30 +0000 (20:28 -0300)
committerSteve French <stfrench@microsoft.com>
Mon, 9 Jan 2023 19:47:02 +0000 (13:47 -0600)
commit29cf28235e3e57e0af01ae29db57a75f87a2ada8
treeab6be977d546b93a402ff22cbc7e12c0f4116deb
parentb7bfaa761d760e72a969d116517eaa12e404c262
cifs: fix file info setting in cifs_query_path_info()

We missed to set file info when CIFSSMBQPathInfo() returned 0, thus
leaving cifs_open_info_data::fi unset.

Fix this by setting cifs_open_info_data::fi when either
CIFSSMBQPathInfo() or SMBQueryInformation() succeed.

Link: https://bugzilla.kernel.org/show_bug.cgi?id=216881
Fixes: 76894f3e2f71 ("cifs: improve symlink handling for smb2+")
Signed-off-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/smb1ops.c