From c65288de4de0552c15d6119098f0eaeb78ab4702 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Date: Thu, 28 Mar 2024 14:20:47 +0400 Subject: [PATCH] plugins: fix -Werror=maybe-uninitialized false-positive MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ../plugins/loader.c:405:15: error: ‘ctx’ may be used uninitialized [-Werror=maybe-uninitialized] Signed-off-by: Marc-André Lureau Reviewed-by: Pierrick Bouvier Message-ID: <20240328102052.3499331-15-marcandre.lureau@redhat.com> Signed-off-by: Philippe Mathieu-Daudé --- plugins/loader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/loader.c b/plugins/loader.c index 9768b78eb6..513a429c57 100644 --- a/plugins/loader.c +++ b/plugins/loader.c @@ -390,7 +390,7 @@ void plugin_reset_uninstall(qemu_plugin_id_t id, bool reset) { struct qemu_plugin_reset_data *data; - struct qemu_plugin_ctx *ctx; + struct qemu_plugin_ctx *ctx = NULL; WITH_QEMU_LOCK_GUARD(&plugin.lock) { ctx = plugin_id_to_ctx_locked(id);