virsh: Error out while domain not found for 'qemu-monitor-event' command

Signed-off-by: Lin Ma <lma@suse.com>
This commit is contained in:
Lin Ma 2018-05-04 17:28:48 +08:00 committed by Peter Krempa
parent b04629b629
commit b925e6625c

View File

@ -9661,7 +9661,9 @@ cmdQemuMonitorEvent(vshControl *ctl, const vshCmd *cmd)
return false;
if (vshCommandOptBool(cmd, "domain"))
dom = virshCommandOptDomain(ctl, cmd, NULL);
if (!(dom = virshCommandOptDomain(ctl, cmd, NULL)))
goto cleanup;
if (vshEventStart(ctl, timeout) < 0)
goto cleanup;