mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 19:32:19 +00:00
qemuMonitorGetAllBlockStatsInfo: virHashNew
cannot return NULL
Signed-off-by: Tim Wiederhake <twiederh@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
389049a4db
commit
1067bf55fe
@ -2155,15 +2155,12 @@ qemuMonitorGetAllBlockStatsInfo(qemuMonitor *mon,
|
||||
bool backingChain)
|
||||
{
|
||||
int ret;
|
||||
g_autoptr(GHashTable) stats = NULL;
|
||||
g_autoptr(GHashTable) stats = virHashNew(g_free);
|
||||
|
||||
VIR_DEBUG("ret_stats=%p, backing=%d", ret_stats, backingChain);
|
||||
|
||||
QEMU_CHECK_MONITOR(mon);
|
||||
|
||||
if (!(stats = virHashNew(g_free)))
|
||||
return -1;
|
||||
|
||||
ret = qemuMonitorJSONGetAllBlockStatsInfo(mon, stats, backingChain);
|
||||
|
||||
if (ret < 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user