diff options
Diffstat (limited to 'ui')
-rw-r--r-- | ui/vnc.c | 18 |
1 files changed, 12 insertions, 6 deletions
@@ -129,10 +129,13 @@ static void vnc_init_basic_info(SocketAddress *addr, info->family = NETWORK_ADDRESS_FAMILY_UNIX; break; - default: - error_setg(errp, "Unsupported socket kind %d", - addr->type); + case SOCKET_ADDRESS_KIND_VSOCK: + case SOCKET_ADDRESS_KIND_FD: + error_setg(errp, "Unsupported socket address type %s", + SocketAddressKind_lookup[addr->type]); break; + default: + abort(); } return; @@ -411,10 +414,13 @@ VncInfo *qmp_query_vnc(Error **errp) info->family = NETWORK_ADDRESS_FAMILY_UNIX; break; - default: - error_setg(errp, "Unsupported socket kind %d", - addr->type); + case SOCKET_ADDRESS_KIND_VSOCK: + case SOCKET_ADDRESS_KIND_FD: + error_setg(errp, "Unsupported socket address type %s", + SocketAddressKind_lookup[addr->type]); goto out_error; + default: + abort(); } info->has_host = true; |