[libvirt] [PATCH 1/7] Change calling conventions in remote driver client internals

Eric Blake eblake at redhat.com
Thu Aug 19 19:50:43 UTC 2010


On 08/17/2010 11:02 AM, Daniel P. Berrange wrote:
> The remoteIO() method has wierd calling conventions, where
> it is passed a pre-allocated 'struct remote_call *' but
> then free()s it itself, instead of letting the caller free().
> This fixes those wierd semantics

s/wierd/weird/g

> 
> * src/remote/remote_driver.c: Santize semantics of remoteIO

s/Santize/Sanitize/

>   method wrt to memory release
> ---
>  src/remote/remote_driver.c |   25 +++++++++++++------------
>  1 files changed, 13 insertions(+), 12 deletions(-)

> @@ -10021,6 +10019,7 @@ call (virConnectPtr conn, struct private_data *priv,
>        xdrproc_t ret_filter, char *ret)
>  {
>      struct remote_thread_call *thiscall;
> +    int rv;

Any reason you used 'ret' in some hunks, but 'rv' in this one?

$ git grep 'return rv;' | wc
    167     501    7084
$ git grep 'return res;' | wc
     12      36     518
$ git grep 'return ret;' | wc
   1250    3838   49749

Consistency argues for naming it 'ret'.

ACK with that nit fixed.

-- 
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/20100819/c75dd46b/attachment-0001.sig>


More information about the libvir-list mailing list