mirror of
https://github.com/clearlinux/uwsgi.git
synced 2026-09-06 05:31:44 +00:00
reapply fixed-SERVER_PORT-in-routers-when-shared-sockets-are.patch
This commit is contained in:
@@ -59,6 +59,14 @@ void uwsgi_corerouter_setup_sockets(struct uwsgi_corerouter *ucr) {
|
||||
uwsgi.no_defer_accept = current_defer_accept;
|
||||
}
|
||||
}
|
||||
// fix SERVER_PORT
|
||||
if (!ugs->port || !ugs->port_len) {
|
||||
ugs->port = strchr(ugs->name, ':');
|
||||
if (ugs->port) {
|
||||
ugs->port++;
|
||||
ugs->port_len = strlen(ugs->port);
|
||||
}
|
||||
}
|
||||
// put socket in non-blocking mode
|
||||
uwsgi_socket_nb(ugs->fd);
|
||||
uwsgi_log("%s bound on %s fd %d\n", ucr->name, ugs->name, ugs->fd);
|
||||
|
||||
Reference in New Issue
Block a user