mirror of
https://github.com/mii443/qemu.git
synced 2025-12-03 11:08:25 +00:00
qapi/qmp: add ObjectPropertyInfo.default-value
Report the default value associated with a property. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20200110153039.1379601-26-marcandre.lureau@redhat.com> [Report it as type "any", not string. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
committed by
Paolo Bonzini
parent
4df8161673
commit
1bb3d7d92c
@@ -177,6 +177,8 @@ ObjectPropertyInfoList *qmp_device_list_properties(const char *typename,
|
||||
info->type = g_strdup(prop->type);
|
||||
info->has_description = !!prop->description;
|
||||
info->description = g_strdup(prop->description);
|
||||
info->default_value = qobject_ref(prop->defval);
|
||||
info->has_default_value = !!info->default_value;
|
||||
|
||||
entry = g_malloc0(sizeof(*entry));
|
||||
entry->value = info;
|
||||
|
||||
Reference in New Issue
Block a user