aboutsummaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorZhang Xiaoxu2022-10-17 22:45:24 +0800
committerSteve French2022-10-18 11:33:43 -0500
commite909d054bdea75ef1ec48c18c5936affdaecbb2c (patch)
tree16d2f88271d7241fb12f732d62574d3aa682cdbe /fs
parent575e079c782b9862ec2626403922d041a42e6ed6 (diff)
cifs: Fix xid leak in cifs_ses_add_channel()
Before return, should free the xid, otherwise, the xid will be leaked. Fixes: d70e9fa55884 ("cifs: try opening channels after mounting") Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz> Signed-off-by: Zhang Xiaoxu <zhangxiaoxu5@huawei.com> Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/cifs/sess.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/cifs/sess.c b/fs/cifs/sess.c
index 0435d1dfa9e1..92e4278ec35d 100644
--- a/fs/cifs/sess.c
+++ b/fs/cifs/sess.c
@@ -496,6 +496,7 @@ out:
cifs_put_tcp_session(chan->server, 0);
}
+ free_xid(xid);
return rc;
}