monitor: Plug memory leak on QMP error
Leak introduced in commit 8a4f501..710aec9, v2.4.0.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <1446117309-15322-1-git-send-email-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Luiz Capitulino <lcapitulino@redhat.com>
diff --git a/monitor.c b/monitor.c
index e4cf34e..49073ac 100644
--- a/monitor.c
+++ b/monitor.c
@@ -3907,6 +3907,7 @@
err_out:
monitor_protocol_emitter(mon, data, local_err);
qobject_decref(data);
+ error_free(local_err);
QDECREF(input);
QDECREF(args);
}