]> www.infradead.org Git - users/jedix/linux-maple.git/commit
smb: client: fix double put of @cfile in smb2_rename_path()
authorPaulo Alcantara <pc@manguebit.com>
Tue, 3 Sep 2024 13:53:23 +0000 (10:53 -0300)
committerSteve French <stfrench@microsoft.com>
Tue, 3 Sep 2024 14:48:50 +0000 (09:48 -0500)
commit3523a3df03c6f04f7ea9c2e7050102657e331a4f
treeb26c058231923b3c762ac5225d9a408ab62c368e
parent7ccc1465465d78e6411b7bd730d06e7435802b5c
smb: client: fix double put of @cfile in smb2_rename_path()

If smb2_set_path_attr() is called with a valid @cfile and returned
-EINVAL, we need to call cifs_get_writable_path() again as the
reference of @cfile was already dropped by previous smb2_compound_op()
call.

Fixes: 71f15c90e785 ("smb: client: retry compound request without reusing lease")
Signed-off-by: Paulo Alcantara (Red Hat) <pc@manguebit.com>
Cc: David Howells <dhowells@redhat.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/smb/client/smb2inode.c