On Fri, Apr 24, 2015 at 2:04 AM, Niklas Edmundsson <[email protected]> wrote: > > When trying to debug something else I stumbled across this code-snippet in > modules/cache/mod_cache.c: > > errno = 0; > x = control.max_age_value; > if (errno) { > x = dconf->defex; > } > else { > x = x * MSEC_ONE_SEC; > } > > It looks that way both in trunk and 2.4.x. > > The likelhood of that if-statement to have more than one outcome is low, and > the fact that errno isn't used anywhere else in mod_cache.c makes it even > more suspicious. > > Looking at the annotated history it seems like the errno-stuff stems from > apr_atoi64() being used once upon a time but has since been removed without > cleaning up the related code... > > It's easy to just remove the now redundant code, but is that the right way > to do it or did the initial code have some function that's now gone missing? >
Just came across the same thing (looking at s-maxage stuff) and found your note searching my mail. I think all of the checking is still present between ap_cache_control and the caller checking control.maxage before looking at control.maxage_value. I just removed the errno stuff in r1718496.
