aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2024-09-24 16:54:34 +0400
committerMarc-André Lureau <marcandre.lureau@redhat.com>2024-10-02 16:14:29 +0400
commit8f3375434d45e56db51b5ecd4d8a929146ba5641 (patch)
treea6d769bce6662b4989c0de7f0793993aac18453f
parent79660687df4ed99117cda77012a8a39616cc6b45 (diff)
downloadqemu-8f3375434d45e56db51b5ecd4d8a929146ba5641.zip
qemu-8f3375434d45e56db51b5ecd4d8a929146ba5641.tar.gz
qemu-8f3375434d45e56db51b5ecd4d8a929146ba5641.tar.bz2
qom/object: fix -Werror=maybe-uninitialized
object_resolve_path_type() sets *ambiguousp only when it is. Fixes: 81c48dd79655 (hw/i386/acpi: Add object_resolve_type_unambiguous to improve modularity) Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
-rw-r--r--qom/object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/qom/object.c b/qom/object.c
index 28c5b66..d3d3003 100644
--- a/qom/object.c
+++ b/qom/object.c
@@ -2226,7 +2226,7 @@ Object *object_resolve_path_at(Object *parent, const char *path)
Object *object_resolve_type_unambiguous(const char *typename, Error **errp)
{
- bool ambig;
+ bool ambig = false;
Object *o = object_resolve_path_type("", typename, &ambig);
if (ambig) {