[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] issue 1780: Keyword values with dollar signs causebadness.

From: Michael Pilato <cmpilato_at_collab.net>
Date: 2006-01-10 15:23:27 CET

On Mon, 2006-01-09 at 21:22 -0500, John Peacock wrote:
> Lieven Govaerts wrote:
> > Can you agree with this change in algorithm? I don't see any problems in
> > the algorithm itself, but there may be some work on the implementation.
> > Performance impact is very low, due to the max. keyword length of 255 chars.
>
> At a cursory glance, it seems like the change would work, but one thing you may
> not be aware of was that SVN_KEYWORD_MAX_LEN #define may change. The reason is
> that it is surprisingly easy to get a path longer than 255 characters in big
> projects (like GCC, to use a real life example). I don't know if the #define is
> going to be eliminated entirely or just increase by a couple powers of two.
> Some testing is going to have to take place as to whether this extra looping
> will have any performance issues.
>
> In any case, some test cases and a good log message (see HACKING) are essential
> to get a thorough review...

Two things:

The algorithm is a pretty good one, though I think it still falls down
if, say, an Author's name begins with a '$'. The expanded form would be
'$ Author: $username $', which happens to be a superset of the
completely valid format '$ Author: $'.

Definitely should use SVN_KEYWORD_MAX_LEN, not a hard-coded 255. I'll
reserve comment on what SVN_KEYWORD_MAX_LEN's numerical equivalent
should be (255 or otherwise).

-- 
C. Michael Pilato <cmpilato@collab.net> 
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand

Received on Tue Jan 10 15:41:02 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.