diff mbox series

vpc: Don't leak opts in vpc_open()

Message ID 20181017133350.14351-1-kwolf@redhat.com (mailing list archive)
State New, archived
Headers show
Series vpc: Don't leak opts in vpc_open() | expand

Commit Message

Kevin Wolf Oct. 17, 2018, 1:33 p.m. UTC
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/vpc.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Alberto Garcia Oct. 17, 2018, 3:29 p.m. UTC | #1
On Wed 17 Oct 2018 03:33:50 PM CEST, Kevin Wolf wrote:
> Signed-off-by: Kevin Wolf <kwolf@redhat.com>

Reviewed-by: Alberto Garcia <berto@igalia.com>

Berto
diff mbox series

Patch

diff --git a/block/vpc.c b/block/vpc.c
index bf294abfa7..eace2ba484 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -454,10 +454,12 @@  static int vpc_open(BlockDriverState *bs, QDict *options, int flags,
     }
 
     qemu_co_mutex_init(&s->lock);
+    qemu_opts_del(opts);
 
     return 0;
 
 fail:
+    qemu_opts_del(opts);
     qemu_vfree(s->pagetable);
 #ifdef CACHE
     g_free(s->pageentry_u8);