From b235efb8d2e421538539655eb1ab18ae01f9decd Mon Sep 17 00:00:00 2001 From: Israel Rukshin Date: Wed, 17 Aug 2016 07:27:38 +0000 Subject: [PATCH] isert: fix missing refcount cleanup at error flow Before calling to rdma_accept isert kref is 2, so on failure we must decrease it twice. Signed-off-by: Israel Rukshin git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@6942 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- iscsi-scst/kernel/isert-scst/iser_rdma.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/iscsi-scst/kernel/isert-scst/iser_rdma.c b/iscsi-scst/kernel/isert-scst/iser_rdma.c index 82b067bd6..48cb109f8 100644 --- a/iscsi-scst/kernel/isert-scst/iser_rdma.c +++ b/iscsi-scst/kernel/isert-scst/iser_rdma.c @@ -1460,7 +1460,8 @@ out: fail_accept: set_bit(ISERT_CONNECTION_ABORTED, &isert_conn->flags); - isert_cm_timewait_exit_handler(cm_id, NULL); + isert_conn_free(isert_conn); + isert_sched_conn_free(isert_conn); err = 0; goto out;