You shouldn't be writing authz files inside merge_tests.py; use
merge_tests_authz.py instead. Unless something's changed while I
wasn't paying attention, authz-based tests aren't safe for parallel
execution, and merge_tests_authz explicitly disables parallelism.
--dave
On Sun, Apr 19, 2009 at 7:27 AM, Lieven Govaerts <lgo_at_mobsol.be> wrote:
> Author: lgo
> Date: Sun Apr 19 07:27:17 2009
> New Revision: 37363
>
> Log:
> Fix abort when merging non-existant subtrees against a 1.5 server.
>
> Found by: Stefan Küng <tortoisesvn_at_gmail.com>
>
> * subversion/libsvn_ra/compat.c
> Â (log_path_del_receiver): when searching the revision in which a path
> Â was deleted, we can encounter revisions that don't contain - readable -
> Â paths. Just exit the function early in this case.
>
> * subversion/tests/cmdline/merge_test.py
> Â (global): import write_authz_file.
> Â (merge_fails_if_subtree_is_deleted_on_src): include an unreadable commit
> Â in the merge revision set, to verify above fix.
>
> Modified:
> Â trunk/subversion/libsvn_ra/compat.c
> Â trunk/subversion/tests/cmdline/merge_tests.py
>
> Modified: trunk/subversion/libsvn_ra/compat.c
> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/libsvn_ra/compat.c?pathrev=37363&r1=37362&r2=37363
> ==============================================================================
> --- trunk/subversion/libsvn_ra/compat.c Sun Apr 19 01:53:34 2009 Â Â Â Â (r37362)
> +++ trunk/subversion/libsvn_ra/compat.c Sun Apr 19 07:27:17 2009 Â Â Â Â (r37363)
> @@ -796,6 +796,10 @@ log_path_del_receiver(void *baton,
> Â {
> Â apr_hash_index_t *hi;
>
> + Â /* No paths were changed in this revision. Â Nothing to do. */
> + Â if (! log_entry->changed_paths2)
> + Â Â return SVN_NO_ERROR;
> +
> Â for (hi = apr_hash_first(pool, log_entry->changed_paths2);
> Â Â Â Â hi != NULL;
> Â Â Â Â hi = apr_hash_next(hi))
>
> Modified: trunk/subversion/tests/cmdline/merge_tests.py
> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/tests/cmdline/merge_tests.py?pathrev=37363&r1=37362&r2=37363
> ==============================================================================
> --- trunk/subversion/tests/cmdline/merge_tests.py    Sun Apr 19 01:53:34 2009     (r37362)
> +++ trunk/subversion/tests/cmdline/merge_tests.py    Sun Apr 19 07:27:17 2009     (r37363)
> @@ -32,6 +32,7 @@ SkipUnless = svntest.testcase.SkipUnless
>
> Â from svntest.main import SVN_PROP_MERGEINFO
> Â from svntest.main import server_has_mergeinfo
> +from svntest.main import write_authz_file
> Â from svntest.actions import fill_file_with_lines
> Â from svntest.actions import make_conflict_marker_text
> Â from svntest.actions import inject_conflict_into_expected_state
> @@ -7026,6 +7027,10 @@ def merge_fails_if_subtree_is_deleted_on
> Â sbox.build()
> Â wc_dir = sbox.wc_dir
>
> + Â write_authz_file(sbox, {"/" : "* = rw",
> + Â Â Â Â Â Â Â Â Â Â Â Â Â "/unrelated" : ("* =\n" +
> + Â Â Â Â Â Â Â Â Â Â Â Â Â svntest.main.wc_author2 + " = rw")})
> +
> Â # Some paths we'll care about
> Â Acopy_path = os.path.join(wc_dir, 'A_copy')
> Â gamma_path = os.path.join(wc_dir, 'A', 'D', 'gamma')
> @@ -7112,15 +7117,23 @@ def merge_fails_if_subtree_is_deleted_on
> Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â A_url + '/D/gamma' + '@4',
> Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Acopy_gamma_path)
>
> + Â # r6: create an empty (unreadable) commit.
> + Â # Empty or unreadable revisions used to crash a svn 1.6+ client when
> + Â # used with a 1.5 server:
> + Â # http://svn.haxx.se/dev/archive-2009-04/0476.shtml
> + Â svntest.main.run_svn(None, 'mkdir', sbox.repo_url + '/unrelated',
> + Â Â Â Â Â Â Â Â Â Â Â '--username', svntest.main.wc_author2,
> + Â Â Â Â Â Â Â Â Â Â Â '-m', 'creating a rev with no paths.')
> +
> Â # This merge causes a tree conflict. Since the result of the previous
> Â # merge of A/D/gamma into A_copy/D has not yet been committed, it is
> Â # considered a local modification of A_Copy/D/gamma by the following
> Â # merge. A delete merged ontop of a modified file is a tree conflict.
> Â # See notes/tree-conflicts/detection.txt
> - Â svntest.actions.run_and_verify_svn(None, expected_merge_output([[5], [3,5]],
> + Â svntest.actions.run_and_verify_svn(None, expected_merge_output([[6], [3,6]],
> Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â ['D Â Â ' + Acopy_gamma_path + '\n',
> Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â 'C Â Â ' + Acopy_D_path + '\n']),
> - Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â [], 'merge', '-r1:5', '--force',
> + Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â [], 'merge', '-r1:6', '--force',
> Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â A_url, Acopy_path)
>
> Â # Test for issue #2976 Subtrees can lose non-inheritable ranges.
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=495&dsMessageId=1807893
>
--
glasser_at_davidglasser.net | langtonlabs.org | flickr.com/photos/glasser/
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2261126
Received on 2009-05-14 20:10:48 CEST