[libvirt] [PATCH] sendkey: use consistent API convention

Eric Blake eblake at redhat.com
Wed Jun 15 17:33:15 UTC 2011


On 06/15/2011 10:46 AM, Daniel P. Berrange wrote:
> On Wed, Jun 15, 2011 at 10:37:49AM -0600, Eric Blake wrote:
>> Even though rpc uses 'unsigned int' for the _val parameter that
>> passes the length of item<length>, the public libvirt APIs all
>> use 'int' and filter out lengths < 0, except for virDomainSendKey.
>>
>> * include/libvirt/libvirt.h.in (virDomainSendKey): All other APIs
>> use int for array length.
>> * src/libvirt.c (virDomainSendKey): Adjust.
>> * src/driver.h (virDrvDomainSendKey): Likewise.
>> * daemon/remote_generator.pl: Likewise.
>> ---
> 
> ACK,
> 
> If we were starting the API from scratch, I'd say we
> should have used 'unsigned int' everywhere. Given our
> existing practice though, we should stick with 'int'
> everywhere.

Thanks for the review; now pushed.

-- 
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/20110615/3f3e65a7/attachment-0001.sig>


More information about the libvir-list mailing list