virsh: fix net-dhcp-leases no output in quiet mode

When run net-dhcp-leases in quiet mode, cannot get
any output.

 # virsh -q net-dhcp-leases default

Signed-off-by: Luyao Huang <lhuang@redhat.com>
This commit is contained in:
Luyao Huang 2014-11-01 18:41:20 +08:00 committed by Martin Kletzander
parent 45d9ea5cdd
commit ff071bc8b2

View File

@ -1377,10 +1377,10 @@ cmdNetworkDHCPLeases(vshControl *ctl, const vshCmd *cmd)
ignore_value(virAsprintf(&cidr_format, "%s/%d", ignore_value(virAsprintf(&cidr_format, "%s/%d",
lease->ipaddr, lease->prefix)); lease->ipaddr, lease->prefix));
vshPrintExtra(ctl, " %-20s %-18s %-9s %-25s %-15s %s\n", vshPrint(ctl, " %-20s %-18s %-9s %-25s %-15s %s\n",
expirytime, EMPTYSTR(lease->mac), expirytime, EMPTYSTR(lease->mac),
EMPTYSTR(typestr), cidr_format, EMPTYSTR(typestr), cidr_format,
EMPTYSTR(lease->hostname), EMPTYSTR(lease->clientid)); EMPTYSTR(lease->hostname), EMPTYSTR(lease->clientid));
VIR_FREE(cidr_format); VIR_FREE(cidr_format);
} }