]> git.pld-linux.org Git - packages/apache.git/blob - apache-reuseport.patch
- rel 2; don't set SO_REUSEPORT when not needed; fix conf files generation
[packages/apache.git] / apache-reuseport.patch
1 commit 20270f8b9d72c39ac8ddd9386c5126fe6cfe3f31
2 Author: jorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>
3 Date:   Fri Mar 17 08:30:16 2017 +0000
4
5     Merge r1777923 from trunk:
6     
7     avoid SO_REUSEPORT w/o ListenCoresBucketsRatio
8     
9     Can lead to unintended/confusing sharing between
10     multiple servers started by the same ID.
11     
12     Submitted by: covener
13     Reviewed by: jorton, covener, wrowe
14     
15     
16     git-svn-id: http://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1787301 13f79535-47bb-0310-9956-ffa450edef68
17
18 diff --git a/server/listen.c b/server/listen.c
19 index 98cd117c..d44c7c9f 100644
20 --- a/server/listen.c
21 +++ b/server/listen.c
22 @@ -153,7 +153,7 @@ static apr_status_t make_sock(apr_pool_t *p, ap_listen_rec *server)
23  #endif
24  
25  #if defined(SO_REUSEPORT)
26 -    if (ap_have_so_reuseport) {
27 +    if (ap_have_so_reuseport && ap_listencbratio > 0) {
28          int thesock;
29          apr_os_sock_get(&thesock, s);
30          if (setsockopt(thesock, SOL_SOCKET, SO_REUSEPORT,
This page took 0.022625 seconds and 3 git commands to generate.