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

Re: [PATCH] Fix bug in recursive authz logic (Was: Re: problem with AUTHZ_SVN_RECURSIVE in mod_authz_svn.c)

From: David Anderson <david.anderson_at_calixo.net>
Date: 2005-07-23 13:52:44 CEST

kfogel@collab.net wrote:
> We generally fix things on trunk first, and then backport to release
> branches. This case is a little odd, because you took your cue from
> a patch by Bernd that was written against 1.2 code -- which you redid
> for trunk code, and then the "backport" of this trunk change was
> simply Bernd's original patch with a few tweaks.

Woops, my first patch eligible for backporting, and I get it all wrong :-).

So, if I understand you correctly, the two patches become:
  - bernd_rinn_authz_bug_trunk.patch corrects the bug in trunk
  - bernd_rinn_authz_bug_1.2.patch corrects the bug using only 1.2 APIs

Each patch is to be commited to its own line, no merging required. Is
that right?

> If you had to fix the bug twice, in two different ways, then there's
> no point expressing one change as a transformation of the other.

In this case, the backport simply implements the missing public API as a
private utility function in authz.c. Given the size of the fix relative
to this reimplementation, two separate independant patches make more sense.

Commit logs follow.

- Dave

[[[
Fix a bug in the authz recursive lookup logic, reported at
http://subversion.tigris.org/servlets/ReadMsg?list=users&msgNo=35734 .

Suggested by: Bernd Rinn <bernd@sdf.lonestar.org>
Patch by: David Anderson <david.anderson@calixo.net>

* subversion/libsvn_repos/authz.c
   (authz_parse_section): use svn_path_is_ancestor to establish
     relationships between paths instead of just strncmp.
* subversion/tests/libsvn_repos/repos-test.c
   (authz): New regression test.
]]]

[[[
Fix the same bug that was fixed on trunk in rXXXXX. The bug made authz
incorrectly consider some authz sections which didn't apply during
recursive lookups.

Patch by: David Anderson <david.anderson@calixo.net>

* subversion/libsvn_repos/authz.c
   (authz_path_is_ancestor): New internal function. Implements the
     missing public API svn_path_is_ancestor, introduced in trunk.
   (authz_parse_section): use authz_path_is_ancestor to establish
     relationships between paths instead of just strncmp.
* subversion/tests/libsvn_repos/repos-test.c
   (authz): New regression test.
]]]

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Received on Sat Jul 23 13:53:49 2005

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