Grand, thanks.  That fix works for me too.

--
Ian.


On Wed, Jan 14, 2009 at 10:55 PM, Javier Miqueleiz <jav...@miqueleiz.com> wrote:
> On Wed, Dec 31, 2008 at 12:20:01PM +0000, Ian Lea wrote:
>> Hi
>>
>>
>> On apache 2.2.10 a config file with these lines
>>
>> <Proxy balancer://xxx>
>>      BalancerMember ajp://localhost:17100 route=yyy ping=10
>> </Proxy>
>>
>> works fine, but on 2.2.11 it fails to parse, showing error
>>
>> Syntax error on line 73 of /opt/apache-2.2.11/conf/test.conf:
>> BalancerMember Ping/Pong timeout has wrong format
>>
>>
>> I see that the changes file includes
>>
>>   mod_proxy: Add the possibility to set the worker parameters
>>   connectiontimeout and ping in milliseconds. [Ruediger Pluem]
>>
>> If I've followed the code path correctly (far from certain),
>> server/util.c says that the following units are understood
>>
>> * ms    : milliseconds
>> * s     : seconds
>> * mi[n] : minutes
>> * h     : hours
>>
>> but adding any of those makes no difference - they all still fail with
>> the parse error.
>>
>>
>> Any suggestions?
>>
>
> Found the same issue here.
>
> Have debugged the problem with gdb. In function 
> util.c:ap_timeout_parameter_parse
> the first errno checking is true, so it returns an error to its caller.
>
> The apr_strings.c:apr_strtoi64 function just above should clear the errno
> variable at the beginning, I think.
>
> The following patch against apr_strings.c works for me.
>
> diff -uNr /httpd-2.2.11/srclib/apr/strings/apr_strings.c.orig \
> /httpd-2.2.11/srclib/apr/strings/apr_strings.c
> --- /httpd-2.2.11/srclib/apr/strings/apr_strings.c.orig  2006-08-03
> +12:55:31.000000000 +0200
> +++ /httpd-2.2.11/srclib/apr/strings/apr_strings.c       2009-01-14
> +23:24:55.000000000 +0100
> @@ -244,6 +244,7 @@
>
>  APR_DECLARE(apr_int64_t) apr_strtoi64(const char *nptr, char **endptr, int 
> base)
>  {
> +    errno = 0;
>  #ifdef APR_INT64_STRFN
>     return APR_INT64_STRFN(nptr, endptr, base);
>  #else
>
> Regards,
>
> Javi.
>
>>
>>
>> --
>> Ian.
>> ian....@gmail.com

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
   "   from the digest: users-digest-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to