Question about CACHE_SEPARATOR in modules/cache/cache_util.h
Hi, in modules/cache/cache_util.h, CACHE_SEPARATOR is defined as: #define CACHE_SEPARATOR ", " I don't see any reason to have 3 spaces here. It is only used within calls to 'cache_strqtok' and scanning 3 times for the same thing is just a waste of time. Did I miss something obvious, or can it be turned in: #define CACHE_SEPARATOR ", " Best regards, CJ
RE: Question about CACHE_SEPARATOR in modules/cache/cache_util.h
> -Original Message- > From: Christophe JAILLET [mailto:christophe.jail...@wanadoo.fr] > Sent: Montag, 26. Oktober 2015 08:06 > To: dev@httpd.apache.org > Subject: Question about CACHE_SEPARATOR in modules/cache/cache_util.h > > Hi, > > in modules/cache/cache_util.h, CACHE_SEPARATOR is defined as: > > #define CACHE_SEPARATOR ", " > > > I don't see any reason to have 3 spaces here. > It is only used within calls to 'cache_strqtok' and scanning 3 times for > the same thing is just a waste of time. > > Did I miss something obvious, or can it be turned in: I cannot see any obvious here either. If it is needed for whatever reason it at least deserves a comment to avoid this question in the future :-). Regards Rüdiger
Re: Question about CACHE_SEPARATOR in modules/cache/cache_util.h
On 26 Oct 2015, at 9:05 AM, Christophe JAILLET wrote: > in modules/cache/cache_util.h, CACHE_SEPARATOR is defined as: > > #define CACHE_SEPARATOR ", " > > > I don't see any reason to have 3 spaces here. > It is only used within calls to 'cache_strqtok' and scanning 3 times for the > same thing is just a waste of time. > > Did I miss something obvious, or can it be turned in: > > #define CACHE_SEPARATOR ", “ Double check whether the spaces are significant, it might be a space and a tab (which would be weird, because it should just say /t then). This might have RFC compliance issues if it was changed, we need to verify what the code does. Regards, Graham —
Re: Question about CACHE_SEPARATOR in modules/cache/cache_util.h
Am 26.10.2015 um 10:11 schrieb Graham Leggett: On 26 Oct 2015, at 9:05 AM, Christophe JAILLET wrote: in modules/cache/cache_util.h, CACHE_SEPARATOR is defined as: #define CACHE_SEPARATOR ", " I don't see any reason to have 3 spaces here. It is only used within calls to 'cache_strqtok' and scanning 3 times for the same thing is just a waste of time. Did I miss something obvious, or can it be turned in: #define CACHE_SEPARATOR ", “ Double check whether the spaces are significant, it might be a space and a tab (which would be weird, because it should just say /t then). This might have RFC compliance issues if it was changed, we need to verify what the code does. The line goes back to https://bz.apache.org/bugzilla/show_bug.cgi?id=50199 where Nick reported the problem and Graham provided the initial patch. The defined tokenizer chars were "comma-space-space-space" from the beginning. But I think Graham pointed into the right direction, probably it should have been "comma-space-tab". Regards, Rainer
Re: Question about CACHE_SEPARATOR in modules/cache/cache_util.h
On 26 Oct 2015, at 2:15 PM, Rainer Jung wrote: > The line goes back to > > https://bz.apache.org/bugzilla/show_bug.cgi?id=50199 > > where Nick reported the problem and Graham provided the initial patch. > > The defined tokenizer chars were "comma-space-space-space" from the > beginning. But I think Graham pointed into the right direction, probably it > should have been "comma-space-tab”. Following the links further into the RFC, this corresponds with LWS, which is either a space or a tab: #define CACHE_SEPARATOR “, \t" Regards, Graham —