diff --git a/tools/virsh-volume.c b/tools/virsh-volume.c index 89ad8ea216..0ca295f3cd 100644 --- a/tools/virsh-volume.c +++ b/tools/virsh-volume.c @@ -88,7 +88,7 @@ vshCommandOptVolBy(vshControl *ctl, const vshCmd *cmd, } if (!vol) { - if (pool) + if (pool || !pooloptname) vshError(ctl, _("failed to get vol '%s'"), n); else vshError(ctl, _("failed to get vol '%s', specifying --%s "