diff options
Diffstat (limited to 'util/qemu-sockets.c')
-rw-r--r-- | util/qemu-sockets.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/util/qemu-sockets.c b/util/qemu-sockets.c index 9e65ebed01..d8183f79d7 100644 --- a/util/qemu-sockets.c +++ b/util/qemu-sockets.c @@ -1336,37 +1336,6 @@ char *socket_address_to_string(struct SocketAddress *addr, Error **errp) return buf; } -SocketAddressLegacy *socket_address_crumple(SocketAddress *addr_flat) -{ - SocketAddressLegacy *addr = g_new(SocketAddressLegacy, 1); - - switch (addr_flat->type) { - case SOCKET_ADDRESS_TYPE_INET: - addr->type = SOCKET_ADDRESS_LEGACY_KIND_INET; - addr->u.inet.data = QAPI_CLONE(InetSocketAddress, - &addr_flat->u.inet); - break; - case SOCKET_ADDRESS_TYPE_UNIX: - addr->type = SOCKET_ADDRESS_LEGACY_KIND_UNIX; - addr->u.q_unix.data = QAPI_CLONE(UnixSocketAddress, - &addr_flat->u.q_unix); - break; - case SOCKET_ADDRESS_TYPE_VSOCK: - addr->type = SOCKET_ADDRESS_LEGACY_KIND_VSOCK; - addr->u.vsock.data = QAPI_CLONE(VsockSocketAddress, - &addr_flat->u.vsock); - break; - case SOCKET_ADDRESS_TYPE_FD: - addr->type = SOCKET_ADDRESS_LEGACY_KIND_FD; - addr->u.fd.data = QAPI_CLONE(String, &addr_flat->u.fd); - break; - default: - abort(); - } - - return addr; -} - SocketAddress *socket_address_flatten(SocketAddressLegacy *addr_legacy) { SocketAddress *addr = g_new(SocketAddress, 1); |