Re: [PATCH v2] virsh: Checking the volume capacity before uploading a new file.

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

 



> +    if (volumeInfo.capacity < length) {
> +        vshError(ctl, _("lenth parameter is bigger than volume %s capacity"), name);
> +        goto cleanup;
> +    }
> +
> +    if (volumeInfo.capacity < fileLen + offset) {
> +        vshError(ctl, _("file is bigger than volume %s capacity"), name);
> +        goto cleanup;
> +    }
> +

I'm not totally right if I split this IF's or join them into a single IF.
I'm assuming that more information is better to understand the error.

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux