set default listen() backlog to 511 on all platforms except FreeBSD
diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c
index 0e732cf..f8bd6b9 100644
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -2219,7 +2219,7 @@
#endif
ls->family = AF_INET;
- ls->conf.backlog = -1;
+ ls->conf.backlog = NGX_LISTEN_BACKLOG;
ls->conf.rcvbuf = -1;
ls->conf.sndbuf = -1;
}
@@ -2570,7 +2570,7 @@
ls->port = u.port;
ls->file_name = cf->conf_file->file.name;
ls->line = cf->conf_file->line;
- ls->conf.backlog = -1;
+ ls->conf.backlog = NGX_LISTEN_BACKLOG;
ls->conf.rcvbuf = -1;
ls->conf.sndbuf = -1;