diff options
author | Wenchao Xia <wenchaoqemu@gmail.com> | 2014-06-18 08:43:30 +0200 |
---|---|---|
committer | Luiz Capitulino <lcapitulino@redhat.com> | 2014-06-23 11:01:25 -0400 |
commit | a589569f2f40a0454b52398035cfe7fbe44ab1e9 (patch) | |
tree | 4051a6ec079d736c41ea1ee07e903e0b9abf36a9 /ui/spice-core.c | |
parent | f6dadb0242029e11640d9434efd39ec8211ea868 (diff) |
qapi: adjust existing defines
In order to let event defines use existing types later, instead of
redefine new ones, some old type defines for spice and vnc are changed,
and BlockErrorAction is moved from block.h to qapi schema. Note that
BlockErrorAction is not merged with BlockdevOnError.
At this point, VncInfo is not made a child of VncBasicInfo, because
VncBasicInfo has mandatory fields where VncInfo makes them optional.
Signed-off-by: Wenchao Xia <wenchaoqemu@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Diffstat (limited to 'ui/spice-core.c')
-rw-r--r-- | ui/spice-core.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ui/spice-core.c b/ui/spice-core.c index d10818a925..8d54fb320f 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -391,15 +391,16 @@ static SpiceChannelList *qmp_query_spice_channels(void) chan = g_malloc0(sizeof(*chan)); chan->value = g_malloc0(sizeof(*chan->value)); + chan->value->base = g_malloc0(sizeof(*chan->value->base)); paddr = (struct sockaddr *)&item->info->paddr_ext; plen = item->info->plen_ext; getnameinfo(paddr, plen, host, sizeof(host), port, sizeof(port), NI_NUMERICHOST | NI_NUMERICSERV); - chan->value->host = g_strdup(host); - chan->value->port = g_strdup(port); - chan->value->family = g_strdup(inet_strfamily(paddr->sa_family)); + chan->value->base->host = g_strdup(host); + chan->value->base->port = g_strdup(port); + chan->value->base->family = inet_netfamily(paddr->sa_family); chan->value->connection_id = item->info->connection_id; chan->value->channel_type = item->info->type; |