Commit 8270b45b authored by Keir Fraser's avatar Keir Fraser Committed by Konrad Rzeszutek Wilk

blkback: Fix potential resource leak.

parent dd367242
...@@ -318,14 +318,14 @@ static int do_block_io_op(blkif_t *blkif) ...@@ -318,14 +318,14 @@ static int do_block_io_op(blkif_t *blkif)
if (RING_REQUEST_CONS_OVERFLOW(&blk_rings->common, rc)) if (RING_REQUEST_CONS_OVERFLOW(&blk_rings->common, rc))
break; break;
pending_req = alloc_req(); if (kthread_should_stop()) {
if (NULL == pending_req) {
blkif->st_oo_req++;
more_to_do = 1; more_to_do = 1;
break; break;
} }
if (kthread_should_stop()) { pending_req = alloc_req();
if (NULL == pending_req) {
blkif->st_oo_req++;
more_to_do = 1; more_to_do = 1;
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment