Patchwork qemu-img: Release refernece to BlockDriverState

login
register
mail settings
Submitter Prasad Joshi
Date March 25, 2014, 8:25 p.m.
Message ID <1395779153-4536-1-git-send-email-prasadjoshi.linux@gmail.com>
Download mbox | patch
Permalink /patch/333701/
State New
Headers show

Comments

Prasad Joshi - March 25, 2014, 8:25 p.m.
Signed-off-by: Prasad Joshi <prasadjoshi.linux@gmail.com>
---
 qemu-img.c | 1 +
 1 file changed, 1 insertion(+)
Eric Blake - March 25, 2014, 9:19 p.m.
On 03/25/2014 02:25 PM, Prasad Joshi wrote:

s/refernece/reference/ in the subject

This is worth including in 2.0

> Signed-off-by: Prasad Joshi <prasadjoshi.linux@gmail.com>
> ---
>  qemu-img.c | 1 +
>  1 file changed, 1 insertion(+)

With subject line fixed:
Reviewed-by: Eric Blake <eblake@redhat.com>

Appears to have been introduced in commit 43526ec
Stefan Hajnoczi - March 26, 2014, 8:57 a.m.
On Wed, Mar 26, 2014 at 01:55:53AM +0530, Prasad Joshi wrote:
> Signed-off-by: Prasad Joshi <prasadjoshi.linux@gmail.com>
> ---
>  qemu-img.c | 1 +
>  1 file changed, 1 insertion(+)

Thanks, applied to my block tree:
https://github.com/stefanha/qemu/commits/block

Stefan

Patch

diff --git a/qemu-img.c b/qemu-img.c
index 2e40cc1..3d110d9 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -1809,6 +1809,7 @@  static ImageInfoList *collect_image_info_list(const char *filename,
         if (err) {
             error_report("%s", error_get_pretty(err));
             error_free(err);
+            bdrv_unref(bs);
             goto err;
         }