cifs: Fix xid leak in cifs_create()
authorZhang Xiaoxu <zhangxiaoxu5@huawei.com>
Mon, 17 Oct 2022 14:45:21 +0000 (22:45 +0800)
committerSteve French <stfrench@microsoft.com>
Tue, 18 Oct 2022 16:33:43 +0000 (11:33 -0500)
commitfee0fb1f15054bb6a0ede452acb42da5bef4d587
treef8ad43387369c2251f6c90f5bccfce77b38cee00
parent9abf2313adc1ca1b6180c508c25f22f9395cc780
cifs: Fix xid leak in cifs_create()

If the cifs already shutdown, we should free the xid before return,
otherwise, the xid will be leaked.

Fixes: 087f757b0129 ("cifs: add shutdown support")
Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Zhang Xiaoxu <zhangxiaoxu5@huawei.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/dir.c