set default listen() backlog to 511 on all platforms except FreeBSD
diff --git a/src/core/ngx_connection.c b/src/core/ngx_connection.c
index 9d22ac6..87219f2 100644
--- a/src/core/ngx_connection.c
+++ b/src/core/ngx_connection.c
@@ -123,7 +123,7 @@
                                           ntohs(sin->sin_port))
                               - ls[i].addr_text.data;
 
-        ls[i].backlog = -1;
+        ls[i].backlog = NGX_LISTEN_BACKLOG;
 
         olen = sizeof(int);