mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 11:22:23 +00:00
rpc: set listen backlog on FDs as well as on other sockets
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
parent
9805256d53
commit
e1f2ec67c2
@ -614,7 +614,7 @@ virLockDaemonSetupNetworkingSystemD(virNetServerPtr srv)
|
||||
#if WITH_GNUTLS
|
||||
NULL,
|
||||
#endif
|
||||
false, 1)))
|
||||
false, 0, 1)))
|
||||
return -1;
|
||||
|
||||
if (virNetServerAddService(srv, svc, NULL) < 0) {
|
||||
|
@ -133,6 +133,7 @@ virNetServerServiceNewFDOrUNIX(const char *path,
|
||||
tls,
|
||||
#endif
|
||||
readonly,
|
||||
max_queued_clients,
|
||||
nrequests_client_max);
|
||||
}
|
||||
}
|
||||
@ -265,6 +266,7 @@ virNetServerServicePtr virNetServerServiceNewFD(int fd,
|
||||
virNetTLSContextPtr tls,
|
||||
#endif
|
||||
bool readonly,
|
||||
size_t max_queued_clients,
|
||||
size_t nrequests_client_max)
|
||||
{
|
||||
virNetServerServicePtr svc;
|
||||
@ -292,6 +294,9 @@ virNetServerServicePtr virNetServerServiceNewFD(int fd,
|
||||
goto error;
|
||||
|
||||
for (i = 0; i < svc->nsocks; i++) {
|
||||
if (virNetSocketListen(svc->socks[i], max_queued_clients) < 0)
|
||||
goto error;
|
||||
|
||||
/* IO callback is initially disabled, until we're ready
|
||||
* to deal with incoming clients */
|
||||
if (virNetSocketAddIOCallback(svc->socks[i],
|
||||
|
@ -74,6 +74,7 @@ virNetServerServicePtr virNetServerServiceNewFD(int fd,
|
||||
virNetTLSContextPtr tls,
|
||||
# endif
|
||||
bool readonly,
|
||||
size_t max_queued_clients,
|
||||
size_t nrequests_client_max);
|
||||
|
||||
virNetServerServicePtr virNetServerServiceNewPostExecRestart(virJSONValuePtr object);
|
||||
|
Loading…
x
Reference in New Issue
Block a user