mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 03:12:22 +00:00
vz: change printing format specifier for network statistics
This is necessary to be able to get statistics for venet0 or "host-routed" adapter, which has -1 index and thus, its statistics is shown as "net.nic4294967295". Signed-off-by: Maxim Nestratov <mnestratov@virtuozzo.com>
This commit is contained in:
parent
4ebb75c364
commit
99fb668ede
@ -4517,7 +4517,7 @@ prlsdkGetNetStats(PRL_HANDLE sdkstats, PRL_HANDLE sdkdom, const char *path,
|
||||
prlsdkCheckRetGoto(pret, cleanup);
|
||||
|
||||
#define PRLSDK_GET_NET_COUNTER(VAL, NAME) \
|
||||
if (virAsprintf(&name, "net.nic%d.%s", net_index, NAME) < 0) \
|
||||
if (virAsprintf(&name, "net.nic%u.%s", net_index, NAME) < 0) \
|
||||
goto cleanup; \
|
||||
if (prlsdkExtractStatsParam(sdkstats, name, &stats->VAL) < 0) \
|
||||
goto cleanup; \
|
||||
|
Loading…
x
Reference in New Issue
Block a user