Commit 947b515a authored by Jim Jagielski's avatar Jim Jagielski
Browse files

Allow smax to be 0

PR 43371


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@702502 13f79535-47bb-0310-9956-ffa450edef68
parent b6580ec3
Loading
Loading
Loading
Loading
+5 −0
Changes for CHANGES: 5 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -5,6 +5,11 @@ Changes with Apache 2.2.10
     mod_proxy_ftp: Prevent XSS attacks when using wildcards in the path of
     the FTP URL. Discovered by Marc Bevand of Rapid7. [Ruediger Pluem]

  *) Allow for smax to be 0 for balancer members so that all idle
     connections are able to be dropped should they exceed ttl.
     PR 43371 [Phil Endecott <spam_from_apache_bugzilla chezphil.org>,
     Jim Jagielski]

  *) mod_proxy_http: Don't trigger a retry by the client if a failure to
     read the response line was the result of a timeout.
     [Adam Woodworth <mirkperl gmail.com>]
+0 −8
Changes for STATUS: 0 added lines, 8 removed lines.
Original line number Diff line number Diff line
@@ -85,14 +85,6 @@ RELEASE SHOWSTOPPERS:
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
  [ start all new proposals below, under PATCHES PROPOSED. ]

   * mod_proxy: Allow for the smax param to be 0, so that all connections
     are available to be dropped, should they be idle long enough.
     PR 43371
     Trunk version of patch:
       http://svn.apache.org/viewvc?rev=697093&view=rev
    Backport version for 2.2.x of patch:
       Trunk version of patch works
   +1: jim, rpluem, gregames

PATCHES PROPOSED TO BACKPORT FROM TRUNK:
  [ New proposals should be added at the end of the list ]
+1 −1
Changes for modules/proxy/mod_proxy.c: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -92,7 +92,7 @@ static const char *set_worker_param(apr_pool_t *p,
    }
    else if (!strcasecmp(key, "ttl")) {
        /* Time in seconds that will destroy all the connections
         * that exced the smax
         * that exceed the smax
         */
        ival = atoi(val);
        if (ival < 1)
+3 −1
Changes for modules/proxy/proxy_util.c: 3 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -1432,6 +1432,7 @@ PROXY_DECLARE(const char *) ap_proxy_add_worker(proxy_worker **worker,
    (*worker)->id   = proxy_lb_workers;
    (*worker)->flush_packets = flush_off;
    (*worker)->flush_wait = PROXY_FLUSH_WAIT;
    (*worker)->smax = -1;
    /* Increase the total worker count */
    proxy_lb_workers++;
    init_conn_pool(p, *worker);
@@ -1452,6 +1453,7 @@ PROXY_DECLARE(proxy_worker *) ap_proxy_create_worker(apr_pool_t *p)
    proxy_worker *worker;
    worker = (proxy_worker *)apr_pcalloc(p, sizeof(proxy_worker));
    worker->id = proxy_lb_workers;
    worker->smax = -1;
    /* Increase the total worker count */
    proxy_lb_workers++;
    init_conn_pool(p, worker);
@@ -1923,7 +1925,7 @@ PROXY_DECLARE(apr_status_t) ap_proxy_initialize_worker(proxy_worker *worker, ser
        if (worker->hmax == 0 || worker->hmax > mpm_threads) {
            worker->hmax = mpm_threads;
        }
        if (worker->smax == 0 || worker->smax > worker->hmax) {
        if (worker->smax == -1 || worker->smax > worker->hmax) {
            worker->smax = worker->hmax;
        }
        /* Set min to be lower then smax */