Message ID | 20160719085432.4572-36-marcandre.lureau@redhat.com |
---|---|
State | New |
Headers | show |
On 07/19/2016 02:54 AM, marcandre.lureau@redhat.com wrote: > From: Marc-André Lureau <marcandre.lureau@redhat.com> > > In all cases, even when the dict doesn't contain 'ram', the qmp response > must be unref. > > Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> > --- > tests/postcopy-test.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Eric Blake <eblake@redhat.com> > > diff --git a/tests/postcopy-test.c b/tests/postcopy-test.c > index 74fa969..f6f6598 100644 > --- a/tests/postcopy-test.c > +++ b/tests/postcopy-test.c > @@ -198,8 +198,8 @@ static uint64_t get_migration_pass(void) > } else { > rsp_ram = qdict_get_qdict(rsp_return, "ram"); > result = qdict_get_try_int(rsp_ram, "dirty-sync-count", 0); > - QDECREF(rsp); > } > + QDECREF(rsp); > return result; > } > >
diff --git a/tests/postcopy-test.c b/tests/postcopy-test.c index 74fa969..f6f6598 100644 --- a/tests/postcopy-test.c +++ b/tests/postcopy-test.c @@ -198,8 +198,8 @@ static uint64_t get_migration_pass(void) } else { rsp_ram = qdict_get_qdict(rsp_return, "ram"); result = qdict_get_try_int(rsp_ram, "dirty-sync-count", 0); - QDECREF(rsp); } + QDECREF(rsp); return result; }