[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH] virsh: Allow starting domains by UUID



On 03/11/2011 04:15 AM, Jiri Denemark wrote:
> ---
>  tools/libvirt-guests.init.sh |    2 +-
>  tools/virsh.c                |    3 ++-
>  2 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/tools/libvirt-guests.init.sh b/tools/libvirt-guests.init.sh
> index 8823d06..e37e55f 100644
> --- a/tools/libvirt-guests.init.sh
> +++ b/tools/libvirt-guests.init.sh
> @@ -164,7 +164,7 @@ start() {
>                  if $guest_running; then
>                      gettext "already active"; echo
>                  else
> -                    retval run_virsh $uri start "$name" >/dev/null && \
> +                    retval run_virsh $uri start "$guest" >/dev/null && \
>                      gettext "done"; echo
>                  fi
>              fi
> diff --git a/tools/virsh.c b/tools/virsh.c
> index a5e9c4f..b42aac4 100644
> --- a/tools/virsh.c
> +++ b/tools/virsh.c
> @@ -1402,7 +1402,8 @@ cmdStart(vshControl *ctl, const vshCmd *cmd)
>      if (!vshConnectionUsability(ctl, ctl->conn))
>          return FALSE;
>  
> -    if (!(dom = vshCommandOptDomainBy(ctl, cmd, NULL, VSH_BYNAME)))
> +    if (!(dom = vshCommandOptDomainBy(ctl, cmd, NULL,
> +                                      VSH_BYNAME | VSH_BYUUID)))

ACK.  How many more of these might we be missing, due to copy-and-paste?

-- 
Eric Blake   eblake redhat com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]