qom/object: fix -Werror=maybe-uninitialized

object_resolve_path_type() sets *ambiguousp only when it is.

Fixes: 81c48dd796 (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>
This commit is contained in:
Marc-André Lureau 2024-09-24 16:54:34 +04:00
parent 79660687df
commit 8f3375434d
1 changed files with 1 additions and 1 deletions

View File

@ -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) {