> This patch removes some magic in request.c. I wrote it coz 2.0.28 didn't > actually work at all for me, coz the magic failed.
++1. Clarity doesn't have to be inconsistent with optimization. In my defense, what existing before was even less legible - I sincerely tryed to improve it before the last set of optimizations were applied (both mine and Brian's.) > -- > http://www.apache-ssl.org/ben.html http://www.thebunker.net/ > > "There is no limit to what a man can do or how far he can go if he > doesn't mind who gets the credit." - Robert Woodruff -------------------------------------------------------------------------------- > --- request.c~ Fri Nov 9 16:54:00 2001 > +++ request.c Sun Dec 2 14:36:48 2001 > @@ -618,12 +618,14 @@ > int res; > char *seg_name; > char *delim; > + int temp_slash=0; > > /* We have no trailing slash, but we sure would appreciate one... > */ > if (sec_idx && r->filename[filename_len-1] != '/') { > r->filename[filename_len++] = '/'; > r->filename[filename_len] = 0; > + temp_slash=1; > } > > /* Begin *this* level by looking for matching <Directory> sections > @@ -791,7 +793,7 @@ > > /* That temporary trailing slash was useful, now drop it. > */ > - if (seg > startseg) { > + if (temp_slash) { > r->filename[--filename_len] = '\0'; > } > >
