[libvirt] [PATCH] remote: fix a memory free error

In function remoteDeserializeDomainDiskErrors, there is a typo. Signed-off-by: Xu Yandong <xuyandong2@huawei.com> --- src/remote/remote_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 8789c5da00..877250d40c 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -1943,7 +1943,7 @@ remoteDeserializeDomainDiskErrors(remote_domain_disk_error *ret_errors_val, error: for (j = 0; j < i; j++) - VIR_FREE(errors[i].disk); + VIR_FREE(errors[j].disk); return -1; } -- 2.18.1

On 9/19/19 5:00 AM, Xu Yandong wrote:
In function remoteDeserializeDomainDiskErrors, there is a typo.
Signed-off-by: Xu Yandong <xuyandong2@huawei.com> ---
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
src/remote/remote_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 8789c5da00..877250d40c 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -1943,7 +1943,7 @@ remoteDeserializeDomainDiskErrors(remote_domain_disk_error *ret_errors_val,
error: for (j = 0; j < i; j++) - VIR_FREE(errors[i].disk); + VIR_FREE(errors[j].disk);
return -1; }

On Thu, Sep 19, 2019 at 04:00:56AM -0400, Xu Yandong wrote:
In function remoteDeserializeDomainDiskErrors, there is a typo.
Signed-off-by: Xu Yandong <xuyandong2@huawei.com> --- src/remote/remote_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com> and pushed Jano
participants (3)
-
Daniel Henrique Barboza
-
Ján Tomko
-
Xu Yandong