[libvirt] [PATCH] Change return value of VIR_DRV_SUPPORTS_FEATURE to bool

Eric Blake eblake at redhat.com
Fri Dec 3 15:38:39 UTC 2010


On 12/03/2010 08:36 AM, Jiri Denemark wrote:
>>> diff --git a/src/driver.h b/src/driver.h
>>> index b770e5e..e797a75 100644
>>> --- a/src/driver.h
>>> +++ b/src/driver.h
>>> @@ -52,12 +52,12 @@ typedef enum {
>>>   * Note that you must check for errors.
>>
>> However, this comment is no longer applicable.  So you'll need a v2 that
>> fixes the documentation, and make it explicit that the macro ignores
>> errors, as well as a cross-reference to the actual function for someone
>> that cares about errors.
> 
> Ah, I haven't noticed that line... What about the following v2?

ACK.

>  /* Internal feature-detection macro.  Don't call drv->supports_feature
> - * directly, because it may be NULL, use this macro instead.
> + * directly if you don't have to, because it may be NULL, use this macro
> + * instead.
>   *
> - * Note that you must check for errors.
> + * Note that this treats a possible error returned by drv->supports_feature
> + * the same as not supported. If you care about the error, call
> + * drv->supports_feature directly.
>   *

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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20101203/519f4c6b/attachment-0001.sig>


More information about the libvir-list mailing list