qmp_chardev_open_socket() initializes SocketChardev member is_unix like
this:

    s->is_unix = sock->addr->type == SOCKET_ADDRESS_KIND_UNIX;

Its only use is

    if (s->is_unix) {
        qemu_chr_set_feature(chr, QEMU_CHAR_FEATURE_FD_PASS);
    }

Same function.  Should @is_unix be a local variable instead of a member?

It opens the connection like this:

        qio_channel_socket_connect_async(sioc, s->addr,
                                         qemu_chr_socket_connected,
                                         chr, NULL);

or like this:

            if (qio_channel_socket_listen_sync(sioc, s->addr, errp) < 0) {
                goto error;
            }

Looks like it supports all SocketAddressKind, including
SOCKET_ADDRESS_KIND_FD.

If you use SOCKET_ADDRESS_KIND_FD, QEMU_CHAR_FEATURE_FD_PASS is not
set.  Should it be set?

Reply via email to