qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH v2 1/1] module: Move local_err initialization to the loop in


From: Richard Henderson
Subject: Re: [PATCH v2 1/1] module: Move local_err initialization to the loop in module_load_qom_all()
Date: Mon, 12 Aug 2024 19:09:42 +1000
User-agent: Mozilla Thunderbird

On 8/12/24 18:57, Alexander Ivanov wrote:
Move local_err initialization inside the loop in the module_load_qom_all()
function. This change ensures that the error variable is reset to NULL for
each iteration of the loop. This prevents triggering assert(*errp == NULL)
failure in error_setv() when local_err is reused in the loop.

Note: The local_err variable is freed in error_report_err() so there is no
any leak.

Signed-off-by: Alexander Ivanov<alexander.ivanov@virtuozzo.com>
---
  util/module.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]