[libvirt] [PATCH] virsh: fix domfsinfo wrong output in quiet mode

https://bugzilla.redhat.com/show_bug.cgi?id=1250287 When run domfsinfo in quiet mode, we cannot get any useful information (just get \n), this is because we didn't use vshPrint to print useful information. Signed-off-by: Luyao Huang <lhuang@redhat.com> --- tools/virsh-domain.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index a61656f..4988ba2 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -12848,10 +12848,10 @@ cmdDomFSInfo(vshControl *ctl, const vshCmd *cmd) _("Mountpoint"), _("Name"), _("Type"), _("Target")); vshPrintExtra(ctl, "-------------------------------------------------------------------\n"); for (i = 0; i < ret; i++) { - vshPrintExtra(ctl, "%-36s %-8s %-8s ", - info[i]->mountpoint, info[i]->name, info[i]->fstype); + vshPrint(ctl, "%-36s %-8s %-8s ", + info[i]->mountpoint, info[i]->name, info[i]->fstype); for (j = 0; j < info[i]->ndevAlias; j++) { - vshPrintExtra(ctl, "%s", info[i]->devAlias[j]); + vshPrint(ctl, "%s", info[i]->devAlias[j]); if (j != info[i]->ndevAlias - 1) vshPrint(ctl, ","); } -- 1.8.3.1

On Wed, Aug 05, 2015 at 11:17:22AM +0800, Luyao Huang wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1250287
When run domfsinfo in quiet mode, we cannot get any useful information (just get \n), this is because we didn't use vshPrint to print useful information.
Signed-off-by: Luyao Huang <lhuang@redhat.com> --- tools/virsh-domain.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
ACK and pushed. Jan

On 08/05/2015 04:05 PM, Ján Tomko wrote:
On Wed, Aug 05, 2015 at 11:17:22AM +0800, Luyao Huang wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1250287
When run domfsinfo in quiet mode, we cannot get any useful information (just get \n), this is because we didn't use vshPrint to print useful information.
Signed-off-by: Luyao Huang <lhuang@redhat.com> --- tools/virsh-domain.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
ACK and pushed.
Thanks a lot for your quick review.
Jan
Luyao
participants (3)
-
Ján Tomko
-
lhuang
-
Luyao Huang