Re: [PATCH v5 4/4] qemu: unlink the error report from VIR_STRDUP.

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

 




On 09/05/2018 12:20 AM, Julio Faracco wrote:
> The function to retrieve the file system info using QEMU-GA is using
> some conditionals to retrieve the info. This is wrong because the error
> of some conditionals will be raised if VIR_STRDUP return errors and not
> if some problem occurred with JSON.
> 
> Signed-off-by: Julio Faracco <jcfaracco@xxxxxxxxx>
> ---
>  src/qemu/qemu_agent.c | 19 +++++++++++++------
>  1 file changed, 13 insertions(+), 6 deletions(-)
> 
> diff --git a/src/qemu/qemu_agent.c b/src/qemu/qemu_agent.c
> index ac728becef..36dc18d72f 100644
> --- a/src/qemu/qemu_agent.c
> +++ b/src/qemu/qemu_agent.c
> @@ -1836,6 +1836,7 @@ qemuAgentGetFSInfo(qemuAgentPtr mon, virDomainFSInfoPtr **info,
>      virJSONValuePtr data;
>      virDomainFSInfoPtr *info_ret = NULL;
>      virPCIDeviceAddress pci_address;
> +    const char *result = NULL;

This can move inside the for loop...

I can move before pushing...

Reviewed-by: John Ferlan <jferlan@xxxxxxxxxx>

John

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux