diff options
author | Juan Quintela | 2019-08-19 18:08:21 +0200 |
---|---|---|
committer | Juan Quintela | 2019-09-03 23:24:42 +0200 |
commit | fc8135c63021e8e442a7a894e5434f210614a73c (patch) | |
tree | 2fbd34e7d7a57cd9f9b31a2695c4d7f6270ebe08 /io | |
parent | socket: Add num connections to qio_channel_socket_async() (diff) | |
download | qemu-fc8135c63021e8e442a7a894e5434f210614a73c.tar.gz qemu-fc8135c63021e8e442a7a894e5434f210614a73c.tar.xz qemu-fc8135c63021e8e442a7a894e5434f210614a73c.zip |
socket: Add num connections to qio_net_listener_open_sync()
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'io')
-rw-r--r-- | io/net-listener.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/io/net-listener.c b/io/net-listener.c index dc81150318..5d8a226872 100644 --- a/io/net-listener.c +++ b/io/net-listener.c @@ -62,6 +62,7 @@ static gboolean qio_net_listener_channel_func(QIOChannel *ioc, int qio_net_listener_open_sync(QIONetListener *listener, SocketAddress *addr, + int num, Error **errp) { QIODNSResolver *resolver = qio_dns_resolver_get_instance(); @@ -82,7 +83,7 @@ int qio_net_listener_open_sync(QIONetListener *listener, for (i = 0; i < nresaddrs; i++) { QIOChannelSocket *sioc = qio_channel_socket_new(); - if (qio_channel_socket_listen_sync(sioc, resaddrs[i], 1, + if (qio_channel_socket_listen_sync(sioc, resaddrs[i], num, err ? NULL : &err) == 0) { success = true; |