On 06/08/2007 05:17 AM, [EMAIL PROTECTED] wrote: > Author: pquerna > Date: Thu Jun 7 20:17:41 2007 > New Revision: 545385 > > URL: http://svn.apache.org/viewvc?view=rev&rev=545385 > Log: > Use the absolute timeout, as provided by mod_ssl, rather than trying to > calculate a relative timeout. (which did it wrong anyways). > > Modified: > httpd/httpd/trunk/modules/ssl/ssl_scache_memcache.c > > Modified: httpd/httpd/trunk/modules/ssl/ssl_scache_memcache.c > URL: > http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/ssl/ssl_scache_memcache.c?view=diff&rev=545385&r1=545384&r2=545385 > ============================================================================== > --- httpd/httpd/trunk/modules/ssl/ssl_scache_memcache.c (original) > +++ httpd/httpd/trunk/modules/ssl/ssl_scache_memcache.c Thu Jun 7 20:17:41 > 2007 > @@ -189,10 +189,6 @@ > return FALSE; > } > > - timeout -= time(NULL); > - > - timeout = apr_time_sec(timeout); > - > rv = apr_memcache_set(memctxt, strkey, (char*)ucp, nData, timeout, 0);
Maybe I am missing the point here, but timeout was already in seconds and according to the docs apr_memcache_set expects the ttl to be set in seconds. So I guess the only thing that was wrong above was timeout = apr_time_sec(timeout); as it tried to convert something to seconds that was already in seconds. Doing timeout -= time(NULL); should work IMHO. Regards RĂ¼diger