[libvirt] [PATCH REPOST 5/6] test: Create local virStoragePoolObjPtr VolLookup APIs

Michal Privoznik mprivozn at redhat.com
Fri Oct 6 09:34:17 UTC 2017


On 10/05/2017 10:23 PM, John Ferlan wrote:
> Rather than accessing privconn->pools.objs[i] in the for loop,
> let's use an @obj variable to make it easier to read the code.
> 
> Signed-off-by: John Ferlan <jferlan at redhat.com>
> ---
>  src/test/test_driver.c | 30 ++++++++++++++++--------------
>  1 file changed, 16 insertions(+), 14 deletions(-)
> 
> diff --git a/src/test/test_driver.c b/src/test/test_driver.c
> index a1a74b8bd1..e84acf3228 100644
> --- a/src/test/test_driver.c
> +++ b/src/test/test_driver.c
> @@ -4905,27 +4905,28 @@ testStorageVolLookupByKey(virConnectPtr conn,
>                            const char *key)
>  {
>      testDriverPtr privconn = conn->privateData;
> +    virStoragePoolObjPtr obj;

How about s/obj/poolObj/ or something so that one know just from looking
whether obj refers to pool or volume. But I don't care that much.

Michal




More information about the libvir-list mailing list