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

Re: [libvirt] [PATCH 4/9] Implement the public API for vol zeroing



According to David Allan on 3/2/2010 3:13 PM:
> + * @flags: future flags, use 0 for now
> + *
> + * Ensure that future reads from the storage volume return zeroes.
> + *
> + * Returns 0 on success, or -1 on error
> + */
> +int
> +virStorageVolZeroOut(virStorageVolPtr vol,
> +                     unsigned int flags)
> +{
> +    virConnectPtr conn;
> +    VIR_DEBUG("vol=%p, flags=%u", vol, flags);

To be future-proof, we should explicitly reject non-zero flags.  That way,
if a newer client contacts an older server with a new flag supported only
by the client, the client doesn't get the mistaken impression that the
server can honor the flag.

-- 
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]