mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-30 00:00:16 +01:00
http: server: _lws_vhost_init_server_af only needed once
If we already have vh_listen_sockfd ready, call _lws_vhost_init_server_af only once, regardless of IPv6 support.
This commit is contained in:
parent
4eab8f5a19
commit
3b0eb45518
1 changed files with 5 additions and 0 deletions
|
@ -458,6 +458,11 @@ _lws_vhost_init_server(const struct lws_context_creation_info *info,
|
||||||
vhost->listen_port == CONTEXT_PORT_NO_LISTEN_SERVER)
|
vhost->listen_port == CONTEXT_PORT_NO_LISTEN_SERVER)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
if (info && info->vh_listen_sockfd) {
|
||||||
|
a.af = AF_UNSPEC;
|
||||||
|
goto single;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Let's figure out what AF(s) we want this vhost to listen on.
|
* Let's figure out what AF(s) we want this vhost to listen on.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Add table
Reference in a new issue