summaryrefslogtreecommitdiffstats
path: root/fs/dlm/lock.c
diff options
context:
space:
mode:
authorVasily Averin <vvs@virtuozzo.com>2018-11-15 11:18:18 +0100
committerDavid Teigland <teigland@redhat.com>2018-11-15 16:57:22 +0100
commit23851e978f31eda8b2d01bd410d3026659ca06c7 (patch)
tree2253374441b316d63d4aae4452dfa5010dc6e76c /fs/dlm/lock.c
parentdlm: fixed memory leaks after failed ls_remove_names allocation (diff)
downloadlinux-23851e978f31eda8b2d01bd410d3026659ca06c7.tar.xz
linux-23851e978f31eda8b2d01bd410d3026659ca06c7.zip
dlm: possible memory leak on error path in create_lkb()
Fixes 3d6aa675fff9 ("dlm: keep lkbs in idr") Cc: stable@kernel.org # 3.1 Signed-off-by: Vasily Averin <vvs@virtuozzo.com> Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm/lock.c')
-rw-r--r--fs/dlm/lock.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c
index cc91963683de..2cb125cc21c9 100644
--- a/fs/dlm/lock.c
+++ b/fs/dlm/lock.c
@@ -1209,6 +1209,7 @@ static int create_lkb(struct dlm_ls *ls, struct dlm_lkb **lkb_ret)
if (rv < 0) {
log_error(ls, "create_lkb idr error %d", rv);
+ dlm_free_lkb(lkb);
return rv;
}