[libvirt] [PATCH] tools: fix the output of blockjob

Peter Krempa pkrempa at redhat.com
Mon May 11 06:05:12 UTC 2015


On Mon, May 11, 2015 at 12:14:57 +0800, Shanzhi Yu wrote:
> There will be no output when use blockjob with "--raw" option if guest
> has no block job. A explicit message should be given just like
> with "--info"

NACK, the --raw mode is for script consumption and thus no output means
there is no block job.

> 
> Signed-off-by: Shanzhi Yu <shyu at redhat.com>
> ---
>  tools/virsh-domain.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c
> index 14e1e35..7094a43 100644
> --- a/tools/virsh-domain.c
> +++ b/tools/virsh-domain.c
> @@ -2541,7 +2541,6 @@ cmdBlockJob(vshControl *ctl, const vshCmd *cmd)
>      }
>  
>      if (rc == 0) {
> -        if (!raw)
>              vshPrint(ctl, _("No current block job for %s"), path);

This line would be incorrectly indented after this patch.

>          ret = true;
>          goto cleanup;

Peter
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20150511/df4f5751/attachment-0001.sig>


More information about the libvir-list mailing list