On Aug 25, 2011, at 4:56 PM, Stefan Fritsch wrote: > > Is it really a good idea to first parse the range string (involving lots of > copying with ap_getword), then format it back into a string just to have it > parsed by parse_byterange again?
It is if we want to be able to create a correct r->range element with ap_set_byterange() Certainly that is where we should be creating the canonical Range: we are using (or figuring out whether to punt it). > I would much prefer to have it parsed only once into an array of values and > then do the merging in that array. This is more efficient and I think it > would also lead to better readability. My original patch for merging/sorting > had some code for that which we could reuse: > > http://mail-archives.apache.org/mod_mbox/httpd-dev/201108.mbox/%3c201108240028.03308...@sfritsch.de%3E >