summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds2015-12-04 21:46:07 +0100
committerLinus Torvalds2015-12-04 21:46:07 +0100
commit849ee3d46a7334e950fb17d1ac2cbe2c6b088f65 (patch)
tree454f08ff92b2767c22ff2eacbc895fb23ff17b2e
parentMerge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/g... (diff)
parentrbd: don't put snap_context twice in rbd_queue_workfn() (diff)
downloadkernel-qcow2-linux-849ee3d46a7334e950fb17d1ac2cbe2c6b088f65.tar.gz
kernel-qcow2-linux-849ee3d46a7334e950fb17d1ac2cbe2c6b088f65.tar.xz
kernel-qcow2-linux-849ee3d46a7334e950fb17d1ac2cbe2c6b088f65.zip
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client
Pull Ceph fix from Sage Weil: "This addresses a refcounting bug that leads to a use-after-free" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: rbd: don't put snap_context twice in rbd_queue_workfn()
-rw-r--r--drivers/block/rbd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 235708c7c46e..81ea69fee7ca 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -3442,6 +3442,7 @@ static void rbd_queue_workfn(struct work_struct *work)
goto err_rq;
}
img_request->rq = rq;
+ snapc = NULL; /* img_request consumes a ref */
if (op_type == OBJ_OP_DISCARD)
result = rbd_img_request_fill(img_request, OBJ_REQUEST_NODATA,