You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by cm...@apache.org on 2013/05/10 16:58:56 UTC

svn commit: r1481041 [37/38] - in /subversion/branches/master-passphrase: ./ build/ build/ac-macros/ build/generator/ build/generator/templates/ contrib/client-side/svncopy/ contrib/hook-scripts/ contrib/server-side/fsfsfixer/ contrib/server-side/fsfsf...

Modified: subversion/branches/master-passphrase/subversion/tests/libsvn_wc/op-depth-test.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/subversion/tests/libsvn_wc/op-depth-test.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/subversion/tests/libsvn_wc/op-depth-test.c (original)
+++ subversion/branches/master-passphrase/subversion/tests/libsvn_wc/op-depth-test.c Fri May 10 14:58:47 2013
@@ -168,12 +168,12 @@ print_row(const nodes_row_t *row,
     props = "";
 
   if (row->repo_revnum == SVN_INVALID_REVNUM)
-    return apr_psprintf(result_pool, "%d, %s, %s%s%s%s%s",
+    return apr_psprintf(result_pool, "%d, \"%s\", \"%s\"%s%s%s%s",
                         row->op_depth, row->local_relpath, row->presence,
                         moved_here_str, moved_to_str,
                         file_external_str, props);
   else
-    return apr_psprintf(result_pool, "%d, %s, %s, %s ^/%s@%d%s%s%s%s",
+    return apr_psprintf(result_pool, "%d, \"%s\", \"%s\", %s ^/%s@%d%s%s%s%s",
                         row->op_depth, row->local_relpath, row->presence,
                         row->op_depth == 0 ? "base" : "copyfrom",
                         row->repo_relpath, (int)row->repo_revnum,
@@ -5653,7 +5653,7 @@ move_update_conflicts(const svn_test_opt
   SVN_ERR(sbox_wc_mkdir(&b, "X/A/B/C/D/E"));
   SVN_ERR(sbox_wc_mkdir(&b, "X/A/B/F"));
   SVN_ERR(sbox_wc_commit(&b, ""));
-  SVN_ERR(sbox_wc_switch(&b, "/X"));
+  SVN_ERR(sbox_wc_switch(&b, "", "/X", svn_depth_infinity));
   SVN_ERR(sbox_wc_update(&b, "", 1));
   SVN_ERR(sbox_wc_move(&b, "A", "A2"));
   SVN_ERR(sbox_wc_move(&b, "A2/B/C", "A2/B/C2"));
@@ -6001,7 +6001,7 @@ switch_move(const svn_test_opts_t *opts,
   SVN_ERR(sbox_wc_commit(&b, ""));
   SVN_ERR(sbox_wc_mkdir(&b, "X/B/D/E/F"));
   SVN_ERR(sbox_wc_commit(&b, ""));
-  SVN_ERR(sbox_wc_switch(&b, "/A"));
+  SVN_ERR(sbox_wc_switch(&b, "", "/A", svn_depth_infinity));
   SVN_ERR(sbox_wc_update(&b, "", 2));
 
   SVN_ERR(sbox_wc_move(&b, "B/C", "C2"));
@@ -6029,7 +6029,7 @@ switch_move(const svn_test_opts_t *opts,
 
   /* Switch "bumps" revisions and paths and raises conflicts just like
      update. */
-  SVN_ERR(sbox_wc_switch(&b, "/X"));
+  SVN_ERR(sbox_wc_switch(&b, "", "/X", svn_depth_infinity));
   {
     nodes_row_t nodes[] = {
       {0, "",        "normal",       3, "X"},
@@ -6634,8 +6634,8 @@ finite_move_update_bump(const svn_test_o
   SVN_ERR(sbox_wc_update(&b, "", 1));
   SVN_ERR(sbox_wc_move(&b, "A/B", "B2"));
   SVN_ERR(sbox_wc_move(&b, "P/Q", "Q2"));
-  SVN_ERR(sbox_wc_update_depth(&b, "A/B", 2, svn_depth_files));
-  SVN_ERR(sbox_wc_update_depth(&b, "P/Q", 2, svn_depth_files));
+  SVN_ERR(sbox_wc_update_depth(&b, "A/B", 2, svn_depth_files, FALSE));
+  SVN_ERR(sbox_wc_update_depth(&b, "P/Q", 2, svn_depth_files, FALSE));
   SVN_ERR(check_tree_conflict_repos_path(&b, "A/B", NULL, NULL));
   err = sbox_wc_resolve(&b, "A/B", svn_depth_empty,
                         svn_wc_conflict_choose_mine_conflict);
@@ -6666,8 +6666,8 @@ finite_move_update_bump(const svn_test_o
   SVN_ERR(sbox_wc_update(&b, "", 1));
   SVN_ERR(sbox_wc_move(&b, "A/B", "B2"));
   SVN_ERR(sbox_wc_move(&b, "P", "P2"));
-  SVN_ERR(sbox_wc_update_depth(&b, "A/B", 2, svn_depth_immediates));
-  SVN_ERR(sbox_wc_update_depth(&b, "P", 2, svn_depth_immediates));
+  SVN_ERR(sbox_wc_update_depth(&b, "A/B", 2, svn_depth_immediates, FALSE));
+  SVN_ERR(sbox_wc_update_depth(&b, "P", 2, svn_depth_immediates, FALSE));
   SVN_ERR(check_tree_conflict_repos_path(&b, "P", NULL, NULL));
   err = sbox_wc_resolve(&b, "P", svn_depth_empty,
                         svn_wc_conflict_choose_mine_conflict);
@@ -6700,8 +6700,8 @@ finite_move_update_bump(const svn_test_o
   SVN_ERR(sbox_wc_update(&b, "", 1));
   SVN_ERR(sbox_wc_move(&b, "A/B/C", "C2"));
   SVN_ERR(sbox_wc_move(&b, "P/Q", "Q2"));
-  SVN_ERR(sbox_wc_update_depth(&b, "A/B/C", 2, svn_depth_empty));
-  SVN_ERR(sbox_wc_update_depth(&b, "P/Q", 2, svn_depth_empty));
+  SVN_ERR(sbox_wc_update_depth(&b, "A/B/C", 2, svn_depth_empty, FALSE));
+  SVN_ERR(sbox_wc_update_depth(&b, "P/Q", 2, svn_depth_empty, FALSE));
   SVN_ERR(check_tree_conflict_repos_path(&b, "P/Q", NULL, NULL));
   err = sbox_wc_resolve(&b, "P/Q", svn_depth_empty,
                         svn_wc_conflict_choose_mine_conflict);
@@ -6749,12 +6749,10 @@ move_away_delete_update(const svn_test_o
   SVN_ERR(sbox_wc_update(&b, "", 1));
   SVN_ERR(sbox_wc_move(&b, "A/B/C", "C2"));
   SVN_ERR(sbox_wc_move(&b, "P/Q", "Q2"));
+
+  /* Update to r2 removes the move sources and clears moved_here from
+     the move destinations. */
   SVN_ERR(sbox_wc_update(&b, "", 2));
-  SVN_ERR(sbox_wc_resolve(&b, "A/B", svn_depth_empty,
-                          svn_wc_conflict_choose_merged));
-  SVN_ERR(sbox_wc_resolve(&b, "P/Q", svn_depth_empty,
-                          svn_wc_conflict_choose_merged));
-  /* Either update or resolve should clear the moved-here flags */
   {
     nodes_row_t nodes[] = {
       {0, "",   "normal", 2, ""},
@@ -7301,7 +7299,7 @@ move_back(const svn_test_opts_t *opts, a
   SVN_ERR(sbox_wc_mkdir(&b, "X/A/B/D"));
   SVN_ERR(sbox_wc_mkdir(&b, "X/E"));
   SVN_ERR(sbox_wc_commit(&b, ""));
-  SVN_ERR(sbox_wc_switch(&b, "/X"));
+  SVN_ERR(sbox_wc_switch(&b, "", "/X", svn_depth_infinity));
 
   SVN_ERR(sbox_wc_move(&b, "A/B", "A/B2"));
   {
@@ -7387,7 +7385,768 @@ move_back(const svn_test_opts_t *opts, a
   return SVN_NO_ERROR;
 }
 
+static svn_error_t *
+move_update_subtree(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+  svn_error_t *err;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "move_update_subtree", opts, pool));
+
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/C"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/C/D"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_mkdir(&b, "X"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 3));
+  SVN_ERR(sbox_wc_copy(&b, "A", "P"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+
+  /* Subtree update is like an interrupted update, it leaves a
+     mixed-revision move source. */
+  SVN_ERR(sbox_wc_move(&b, "A/B", "A/B2"));
+  SVN_ERR(sbox_wc_update(&b, "A/B/C", 2));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, ""},
+      {0, "A",       "normal",       1, "A"},
+      {0, "A/B",     "normal",       1, "A/B"},
+      {0, "A/B/C",   "normal",       2, "A/B/C"},
+      {0, "A/B/C/D", "normal",       2, "A/B/C/D"},
+      {2, "A/B",     "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",   "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D", "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",    "normal",       1, "A/B", MOVED_HERE},
+      {2, "A/B2/C",  "normal",       1, "A/B/C", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Resolve fails because of the mixed-revision. */
+  err = sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                        svn_wc_conflict_choose_mine_conflict);
+  SVN_TEST_ASSERT_ERROR(err, SVN_ERR_WC_CONFLICT_RESOLVER_FAILURE);
+
+  /* Update to single-revision to allow resolve; this requires update
+     while the tree-conflict on A/B is present. */
+  SVN_ERR(sbox_wc_update(&b, "A/B", 2));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, ""},
+      {0, "A",       "normal",       1, "A"},
+      {0, "A/B",     "normal",       2, "A/B"},
+      {0, "A/B/C",   "normal",       2, "A/B/C"},
+      {0, "A/B/C/D", "normal",       2, "A/B/C/D"},
+      {2, "A/B",     "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",   "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D", "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",    "normal",       1, "A/B", MOVED_HERE},
+      {2, "A/B2/C",  "normal",       1, "A/B/C", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Now resolve is possible. */
+  SVN_ERR(sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                          svn_wc_conflict_choose_mine_conflict));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       1, "A"},
+      {0, "A/B",      "normal",       2, "A/B"},
+      {0, "A/B/C",    "normal",       2, "A/B/C"},
+      {0, "A/B/C/D",  "normal",       2, "A/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       2, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       2, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       2, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Subtree update that only bumps. */
+  SVN_ERR(sbox_wc_update(&b, "A/B/C", 3));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       1, "A"},
+      {0, "A/B",      "normal",       2, "A/B"},
+      {0, "A/B/C",    "normal",       3, "A/B/C"},
+      {0, "A/B/C/D",  "normal",       3, "A/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       2, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       2, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       2, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Resolve fails because of the mixed-revision. */
+  err = sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                        svn_wc_conflict_choose_mine_conflict);
+  SVN_TEST_ASSERT_ERROR(err, SVN_ERR_WC_CONFLICT_RESOLVER_FAILURE);
+
+  /* Update allowed while tree-conflict is present. */
+  SVN_ERR(sbox_wc_update(&b, "A/B", 3));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       1, "A"},
+      {0, "A/B",      "normal",       3, "A/B"},
+      {0, "A/B/C",    "normal",       3, "A/B/C"},
+      {0, "A/B/C/D",  "normal",       3, "A/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       2, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       2, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       2, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Now resolve works. */
+  SVN_ERR(sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                          svn_wc_conflict_choose_mine_conflict));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       1, "A"},
+      {0, "A/B",      "normal",       3, "A/B"},
+      {0, "A/B/C",    "normal",       3, "A/B/C"},
+      {0, "A/B/C/D",  "normal",       3, "A/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       3, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       3, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       3, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Partial switch of source. */
+  SVN_ERR(sbox_wc_switch(&b, "A", "/P", svn_depth_immediates));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       4, "P"},
+      {0, "A/B",      "normal",       4, "P/B"},
+      {0, "A/B/C",    "normal",       3, "A/B/C"},
+      {0, "A/B/C/D",  "normal",       3, "A/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       3, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       3, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       3, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Resolve fails because of the subtree-switch. */
+  err = sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                        svn_wc_conflict_choose_mine_conflict);
+  SVN_TEST_ASSERT_ERROR(err, SVN_ERR_WC_CONFLICT_RESOLVER_FAILURE);
+
+  /* Switch works while tree-conflict is present. */
+  SVN_ERR(sbox_wc_switch(&b, "A", "/P", svn_depth_infinity));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       4, "P"},
+      {0, "A/B",      "normal",       4, "P/B"},
+      {0, "A/B/C",    "normal",       4, "P/B/C"},
+      {0, "A/B/C/D",  "normal",       4, "P/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       3, "A/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       3, "A/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       3, "A/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Now resolve works. */
+  SVN_ERR(sbox_wc_resolve(&b, "A/B", svn_depth_empty,
+                          svn_wc_conflict_choose_mine_conflict));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       4, "P"},
+      {0, "A/B",      "normal",       4, "P/B"},
+      {0, "A/B/C",    "normal",       4, "P/B/C"},
+      {0, "A/B/C/D",  "normal",       4, "P/B/C/D"},
+      {2, "A/B",      "base-deleted", NO_COPY_FROM, "A/B2"},
+      {2, "A/B/C",    "base-deleted", NO_COPY_FROM},
+      {2, "A/B/C/D",  "base-deleted", NO_COPY_FROM},
+      {2, "A/B2",     "normal",       4, "P/B", MOVED_HERE},
+      {2, "A/B2/C",   "normal",       4, "P/B/C", MOVED_HERE},
+      {2, "A/B2/C/D", "normal",       4, "P/B/C/D", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
+move_parent_into_child(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "move_parent_into_child", opts, pool));
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+
+  SVN_ERR(sbox_wc_move(&b, "A/B", "B2"));
+  SVN_ERR(sbox_wc_move(&b, "A", "B2/A"));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       1, "A"},
+      {0, "A/B",    "normal",       1, "A/B"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "B2/A"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "B2",     "normal",       1, "A/B", MOVED_HERE},
+      {2, "B2/A",   "normal",       1, "A", MOVED_HERE},
+      {2, "B2/A/B", "normal",       1, "A/B", MOVED_HERE},
+      {3, "B2/A/B", "base-deleted", NO_COPY_FROM, "B2"},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  SVN_ERR(sbox_wc_move(&b, "B2", "A"));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",      "normal",       1, ""},
+      {0, "A",     "normal",       1, "A"},
+      {0, "A/B",   "normal",       1, "A/B"},
+      {1, "A",     "normal",       1, "A/B", FALSE, "A/A", TRUE},
+      {1, "A/B",   "base-deleted", NO_COPY_FROM},
+      {2, "A/A",   "normal",       1, "A", MOVED_HERE},
+      {2, "A/A/B", "normal",       1, "A/B", MOVED_HERE},
+      {3, "A/A/B", "base-deleted", NO_COPY_FROM, "A"},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  SVN_ERR(sbox_wc_move(&b, "A/A", "A/B"));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",      "normal",       1, ""},
+      {0, "A",     "normal",       1, "A"},
+      {0, "A/B",   "normal",       1, "A/B"},
+      {1, "A",     "normal",       1, "A/B", FALSE, "A/B", TRUE},
+      {1, "A/B",   "base-deleted", NO_COPY_FROM},
+      {2, "A/B",   "normal",       1, "A", MOVED_HERE},
+      {2, "A/B/B", "normal",       1, "A/B", MOVED_HERE},
+      {3, "A/B/B", "base-deleted", NO_COPY_FROM, "A"},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
+move_depth_expand(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "move_depth_expand", opts, pool));
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A/A"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 0));
+
+  SVN_ERR(sbox_wc_update_depth(&b, "", 1, svn_depth_immediates, TRUE));
+  SVN_ERR(sbox_wc_update_depth(&b, "A", 1, svn_depth_immediates, TRUE));
+  /* Make A/B not present */
+  SVN_ERR(sbox_wc_update_depth(&b, "A/B", 0, svn_depth_immediates, TRUE));
+
+  SVN_ERR(sbox_wc_move(&b, "A", "C"));
+  SVN_ERR(sbox_wc_mkdir(&b, "C/A/A")); /* Local addition obstruction */
+  SVN_ERR(sbox_wc_copy(&b, "C/A", "C/B")); /* Copied obstruction */
+
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, "" },
+
+      {0, "A",      "normal",       1, "A" },
+      {1, "A",      "base-deleted", NO_COPY_FROM, "C" },
+      {0, "A/A",    "normal",       1, "A/A" },
+      {1, "A/A",    "base-deleted", NO_COPY_FROM },
+      {0, "A/B",    "not-present",  0, "A/B" },
+
+      {1, "C",      "normal",       1, "A", MOVED_HERE },
+
+      {1, "C/A",    "normal",       1, "A/A", MOVED_HERE },
+      {3, "C/A/A",  "normal",       NO_COPY_FROM },
+
+      {1, "C/B",    "not-present",  0, "A/B", MOVED_HERE},
+      {2, "C/B",    "normal",       1, "A/A" },
+      {3, "C/B/A",  "normal",       NO_COPY_FROM },
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  SVN_ERR(sbox_wc_update_depth(&b, "", 1, svn_depth_infinity, TRUE));
+
+  /* This used to cause a segfault. Then it asserted in a different place */
+  SVN_ERR(sbox_wc_resolve(&b, "A", svn_depth_empty,
+                          svn_wc_conflict_choose_mine_conflict));
+
+  /* And now verify that there are no not-present nodes left and a
+     consistent working copy */
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, "" },
+
+      {0, "A",       "normal",       1, "A" },
+      {0, "A/A",     "normal",       1, "A/A" },
+      {0, "A/A/A",   "normal",       1, "A/A/A" },
+      {0, "A/A/A/A", "normal",       1, "A/A/A/A" },
+      {0, "A/B",     "normal",       1, "A/B" },
+      {0, "A/B/A",   "normal",       1, "A/B/A" },
+      {0, "A/B/A/A", "normal",       1, "A/B/A/A" },
+
+      {1, "A",       "base-deleted", NO_COPY_FROM, "C" },
+      {1, "A/A",     "base-deleted", NO_COPY_FROM },
+      {1, "A/A/A",   "base-deleted", NO_COPY_FROM },
+      {1, "A/B",     "base-deleted", NO_COPY_FROM },
+      {1, "A/B/A",   "base-deleted", NO_COPY_FROM },
+      {1, "A/B/A/A", "base-deleted", NO_COPY_FROM },
+      {1, "A/A/A/A", "base-deleted", NO_COPY_FROM },
+
+
+      {1, "C",       "normal",       1, "A", MOVED_HERE },
+      {1, "C/A",     "normal",       1, "A/A", MOVED_HERE },
+      {1, "C/A/A",   "normal",       1, "A/A/A", MOVED_HERE },
+      {1, "C/A/A/A", "normal",       1, "A/A/A/A", MOVED_HERE },
+
+      {3, "C/A/A",   "normal",       NO_COPY_FROM },
+      {3, "C/A/A/A", "base-deleted", NO_COPY_FROM },
 
+      {1, "C/B",     "normal",       1, "A/B", MOVED_HERE },
+      {1, "C/B/A",   "normal",       1, "A/B/A", MOVED_HERE },
+      {1, "C/B/A/A", "normal",       1, "A/B/A/A", MOVED_HERE },
+
+      {2, "C/B",     "normal",       1, "A/A" },
+      {2, "C/B/A",   "base-deleted", NO_COPY_FROM },
+      {2, "C/B/A/A", "base-deleted", NO_COPY_FROM },
+
+      {3, "C/B/A",   "normal",       NO_COPY_FROM },
+
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
+move_retract(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "move_retract", opts, pool));
+
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A/C"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/A/A/D"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A/A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A/C"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/A/D"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_delete(&b, "A/A/A/A"));
+  SVN_ERR(sbox_wc_delete(&b, "A/A/A/C"));
+  SVN_ERR(sbox_wc_delete(&b, "A/A/A/D"));
+  SVN_ERR(sbox_wc_delete(&b, "A/B/A/C"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+  SVN_ERR(sbox_wc_move(&b, "A/B/A/D", "D"));
+  SVN_ERR(sbox_wc_delete(&b, "A/B"));
+  SVN_ERR(sbox_wc_move(&b, "A/A", "A/B"));
+
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, "" },
+
+      {0, "A",       "normal",       1, "A" },
+      {0, "A/A",     "normal",       1, "A/A" },
+      {0, "A/A/A",   "normal",       1, "A/A/A" },
+      {0, "A/A/A/A", "normal",       1, "A/A/A/A" },
+      {0, "A/A/A/C", "normal",       1, "A/A/A/C" },
+      {0, "A/A/A/D", "normal",       1, "A/A/A/D" },
+
+      {2, "A/A",     "base-deleted", NO_COPY_FROM, "A/B"},
+      {2, "A/A/A",   "base-deleted", NO_COPY_FROM },
+      {2, "A/A/A/A", "base-deleted", NO_COPY_FROM },
+      {2, "A/A/A/C", "base-deleted", NO_COPY_FROM },
+      {2, "A/A/A/D", "base-deleted", NO_COPY_FROM },
+
+      {0, "A/B",     "normal",       1, "A/B" },
+      {0, "A/B/A",   "normal",       1, "A/B/A" },
+      {0, "A/B/A/A", "normal",       1, "A/B/A/A" },
+      {0, "A/B/A/C", "normal",       1, "A/B/A/C" },
+      {0, "A/B/A/D", "normal",       1, "A/B/A/D" },
+
+      {2, "A/B",     "normal",       1, "A/A", MOVED_HERE },
+      {2, "A/B/A",   "normal",       1, "A/A/A", MOVED_HERE },
+      {2, "A/B/A/A", "normal",       1, "A/A/A/A", MOVED_HERE },
+      {2, "A/B/A/C", "normal",       1, "A/A/A/C", MOVED_HERE },
+      {2, "A/B/A/D", "normal",       1, "A/A/A/D", FALSE, "D", TRUE },
+
+      {1, "D",       "normal",       1, "A/B/A/D", MOVED_HERE },
+
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  SVN_ERR(sbox_wc_update(&b, "", 2));
+
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       2, "" },
+
+      {0, "A",       "normal",       2, "A" },
+      {0, "A/A",     "normal",       2, "A/A" },
+      {0, "A/A/A",   "normal",       2, "A/A/A" },
+
+      {2, "A/A",     "base-deleted", NO_COPY_FROM, "A/B"},
+      {2, "A/A/A",   "base-deleted", NO_COPY_FROM },
+
+      {0, "A/B",     "normal",       2, "A/B" },
+      {0, "A/B/A",   "normal",       2, "A/B/A" },
+      {0, "A/B/A/A", "normal",       2, "A/B/A/A" },
+      {0, "A/B/A/D", "normal",       2, "A/B/A/D" },
+
+      {2, "A/B",     "normal",       1, "A/A", MOVED_HERE },
+      {2, "A/B/A",   "normal",       1, "A/A/A", MOVED_HERE },
+      {2, "A/B/A/A", "normal",       1, "A/A/A/A", MOVED_HERE },
+      {2, "A/B/A/C", "normal",       1, "A/A/A/C", MOVED_HERE },
+      {2, "A/B/A/D", "normal",       1, "A/A/A/D", FALSE, "D", TRUE },
+
+      {1, "D",       "normal",       1, "A/B/A/D", MOVED_HERE },
+
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+
+  SVN_ERR(sbox_wc_resolve(&b, "A/A", svn_depth_empty,
+                          svn_wc_conflict_choose_mine_conflict));
+
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       2, "" },
+
+      {0, "A",       "normal",       2, "A" },
+      {0, "A/A",     "normal",       2, "A/A" },
+      {0, "A/A/A",   "normal",       2, "A/A/A" },
+
+      {0, "A/B",     "normal",       2, "A/B" },
+      {0, "A/B/A",   "normal",       2, "A/B/A" },
+      {0, "A/B/A/A", "normal",       2, "A/B/A/A" },
+      {0, "A/B/A/D", "normal",       2, "A/B/A/D" },
+
+      {2, "A/A",     "base-deleted", NO_COPY_FROM, "A/B"},
+      {2, "A/A/A",   "base-deleted", NO_COPY_FROM },
+
+      {2, "A/B",     "normal",       2, "A/A", MOVED_HERE },
+      {2, "A/B/A",   "normal",       2, "A/A/A", MOVED_HERE },
+      {2, "A/B/A/A", "base-deleted", NO_COPY_FROM }, /* ### MISSING! */
+      {2, "A/B/A/D", "base-deleted", NO_COPY_FROM, "D" }, /* ### MISSING! */
+
+      /* Still conflicted */
+      {1, "D",       "normal",       1, "A/B/A/D", MOVED_HERE },
+
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* ### TODO: Resolve via which specific target? */
+  SVN_ERR(sbox_wc_resolve(&b, "", svn_depth_infinity,
+                          svn_wc_conflict_choose_mine_conflict));
+
+  {
+    nodes_row_t nodes[] = {
+
+      {1, "D",       "normal",       2, "A/B/A/D", MOVED_HERE },
+
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "D", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
+move_delete_file_externals(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "move_delete_file_externals", opts,
+                                   pool));
+
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  sbox_file_write(&b, "f", "New file");
+  SVN_ERR(sbox_wc_add(&b, "f"));
+  SVN_ERR(sbox_wc_propset(&b, "svn:externals", "^/f B/P/g", "A"));
+  SVN_ERR(sbox_wc_propset(&b, "svn:externals", "^/f Q/g\n^/f g", "A/B"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, ""},
+      {0, "A",       "normal",       1, "A"},
+      {0, "A/B",     "normal",       1, "A/B"},
+      {0, "f",       "normal",       1, "f"},
+      {0, "A/B/g",   "normal",       1, "f", TRUE},
+      {0, "A/B/P/g", "normal",       1, "f", TRUE},
+      {0, "A/B/Q/g", "normal",       1, "f", TRUE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Delete removes the file external rows. */
+  SVN_ERR(sbox_wc_delete(&b, "A"));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",    "normal",       1, ""},
+      {0, "A",   "normal",       1, "A"},
+      {0, "A/B", "normal",       1, "A/B"},
+      {0, "f",   "normal",       1, "f"},
+      {1, "A",   "base-deleted", NO_COPY_FROM},
+      {1, "A/B", "base-deleted", NO_COPY_FROM},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Revert doesn't restore the file external rows... */
+  SVN_ERR(sbox_wc_revert(&b, "A", svn_depth_infinity));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",    "normal",       1, ""},
+      {0, "A",   "normal",       1, "A"},
+      {0, "A/B", "normal",       1, "A/B"},
+      {0, "f",   "normal",       1, "f"},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+  /* ... but update does. */
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",        "normal",       1, ""},
+      {0, "A",       "normal",       1, "A"},
+      {0, "A/B",     "normal",       1, "A/B"},
+      {0, "f",       "normal",       1, "f"},
+      {0, "A/B/g",   "normal",       1, "f", TRUE},
+      {0, "A/B/P/g", "normal",       1, "f", TRUE},
+      {0, "A/B/Q/g", "normal",       1, "f", TRUE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Move removes the file external rows. */
+  SVN_ERR(sbox_wc_move(&b, "A", "A2"));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",     "normal",       1, ""},
+      {0, "A",    "normal",       1, "A"},
+      {0, "A/B",  "normal",       1, "A/B"},
+      {0, "f",    "normal",       1, "f"},
+      {1, "A",    "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",  "base-deleted", NO_COPY_FROM},
+      {1, "A2",   "normal",       1, "A", MOVED_HERE},
+      {1, "A2/B", "normal",       1, "A/B", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+  /* Update adds file external rows to the copy. */
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",         "normal",       1, ""},
+      {0, "A",        "normal",       1, "A"},
+      {0, "A/B",      "normal",       1, "A/B"},
+      {0, "f",        "normal",       1, "f"},
+      {1, "A",        "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",      "base-deleted", NO_COPY_FROM},
+      {1, "A2",       "normal",       1, "A", MOVED_HERE},
+      {1, "A2/B",     "normal",       1, "A/B", MOVED_HERE},
+      {0, "A2/B/g",   "normal",       1, "f", TRUE},
+      {0, "A2/B/P/g", "normal",       1, "f", TRUE},
+      {0, "A2/B/Q/g", "normal",       1, "f", TRUE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
+update_with_tree_conflict(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  svn_test__sandbox_t b;
+
+  SVN_ERR(svn_test__sandbox_create(&b, "update_with_tree_conflict", opts,
+                                   pool));
+
+  SVN_ERR(sbox_wc_mkdir(&b, "A"));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_mkdir(&b, "A/B/C"));
+  SVN_ERR(sbox_wc_commit(&b, ""));
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+  SVN_ERR(sbox_wc_move(&b, "A", "A2"));
+
+  SVN_ERR(sbox_wc_update_depth(&b, "A", 2, svn_depth_empty, FALSE));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       2, "A"},
+      {0, "A/B",    "normal",       1, "A/B"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "A2",     "normal",       1, "A", MOVED_HERE},
+      {1, "A2/B",   "normal",       1, "A/B", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  SVN_ERR(sbox_wc_update(&b, "A", 2));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       2, "A"},
+      {0, "A/B",    "normal",       2, "A/B"},
+      {0, "A/B/C",  "normal",       2, "A/B/C"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "A/B/C",  "base-deleted", NO_COPY_FROM},
+      {1, "A2",     "normal",       1, "A", MOVED_HERE},
+      {1, "A2/B",   "normal",       1, "A/B", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Second update overwrote the existing tree-conflict and that
+     causes the move-update to assert. */
+  SVN_ERR(sbox_wc_resolve(&b, "A", svn_depth_infinity,
+                          svn_wc_conflict_choose_mine_conflict));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       2, "A"},
+      {0, "A/B",    "normal",       2, "A/B"},
+      {0, "A/B/C",  "normal",       2, "A/B/C"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "A/B/C",  "base-deleted", NO_COPY_FROM},
+      {1, "A2",     "normal",       2, "A", MOVED_HERE},
+      {1, "A2/B",   "normal",       2, "A/B", MOVED_HERE},
+      {1, "A2/B/C", "normal",       2, "A/B/C", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  /* Same again but second update is A/B rather than A which triggers
+     the problem through open_root rather than open_directory. */
+  SVN_ERR(sbox_wc_revert(&b, "", svn_depth_infinity));
+  SVN_ERR(sbox_wc_update(&b, "", 1));
+  SVN_ERR(sbox_wc_move(&b, "A", "A2"));
+  SVN_ERR(sbox_wc_update_depth(&b, "A", 2, svn_depth_empty, FALSE));
+  SVN_ERR(sbox_wc_update(&b, "A/B", 2));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       2, "A"},
+      {0, "A/B",    "normal",       2, "A/B"},
+      {0, "A/B/C",  "normal",       2, "A/B/C"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "A/B/C",  "base-deleted", NO_COPY_FROM},
+      {1, "A2",     "normal",       1, "A", MOVED_HERE},
+      {1, "A2/B",   "normal",       1, "A/B", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+  SVN_ERR(sbox_wc_resolve(&b, "A", svn_depth_infinity,
+                          svn_wc_conflict_choose_mine_conflict));
+  {
+    nodes_row_t nodes[] = {
+      {0, "",       "normal",       1, ""},
+      {0, "A",      "normal",       2, "A"},
+      {0, "A/B",    "normal",       2, "A/B"},
+      {0, "A/B/C",  "normal",       2, "A/B/C"},
+      {1, "A",      "base-deleted", NO_COPY_FROM, "A2"},
+      {1, "A/B",    "base-deleted", NO_COPY_FROM},
+      {1, "A/B/C",  "base-deleted", NO_COPY_FROM},
+      {1, "A2",     "normal",       2, "A", MOVED_HERE},
+      {1, "A2/B",   "normal",       2, "A/B", MOVED_HERE},
+      {1, "A2/B/C", "normal",       2, "A/B/C", MOVED_HERE},
+      {0}
+    };
+    SVN_ERR(check_db_rows(&b, "", nodes));
+  }
+
+  return SVN_NO_ERROR;
+}
 
 /* ---------------------------------------------------------------------- */
 /* The list of test functions */
@@ -7530,5 +8289,17 @@ struct svn_test_descriptor_t test_funcs[
                        "new_basemove"),
     SVN_TEST_OPTS_PASS(move_back,
                        "move_back (issue 4302)"),
+    SVN_TEST_OPTS_PASS(move_update_subtree,
+                       "move_update_subtree (issue 4232)"),
+    SVN_TEST_OPTS_PASS(move_parent_into_child,
+                       "move_parent_into_child (issue 4333)"),
+    SVN_TEST_OPTS_PASS(move_depth_expand,
+                       "move depth expansion"),
+    SVN_TEST_OPTS_PASS(move_retract,
+                       "move retract (issue 4336)"),
+    SVN_TEST_OPTS_PASS(move_delete_file_externals,
+                       "move/delete file externals (issue 4293)"),
+    SVN_TEST_OPTS_PASS(update_with_tree_conflict,
+                       "update with tree conflict (issue 4347)"),
     SVN_TEST_NULL
   };

Modified: subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.c (original)
+++ subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.c Fri May 10 14:58:47 2013
@@ -317,7 +317,8 @@ svn_error_t *
 sbox_wc_update_depth(svn_test__sandbox_t *b,
                      const char *path,
                      svn_revnum_t revnum,
-                     svn_depth_t depth)
+                     svn_depth_t depth,
+                     svn_boolean_t sticky)
 {
   svn_client_ctx_t *ctx;
   apr_array_header_t *result_revs;
@@ -332,19 +333,22 @@ sbox_wc_update_depth(svn_test__sandbox_t
   SVN_ERR(svn_client_create_context2(&ctx, NULL, b->pool));
   ctx->wc_ctx = b->wc_ctx;
   return svn_client_update4(&result_revs, paths, &revision, depth,
-                            FALSE, FALSE, FALSE, FALSE, FALSE,
+                            sticky, FALSE, FALSE, FALSE, FALSE,
                             ctx, b->pool);
 }
 
 svn_error_t *
 sbox_wc_update(svn_test__sandbox_t *b, const char *path, svn_revnum_t revnum)
 {
-  SVN_ERR(sbox_wc_update_depth(b, path, revnum, svn_depth_infinity));
+  SVN_ERR(sbox_wc_update_depth(b, path, revnum, svn_depth_unknown, FALSE));
   return SVN_NO_ERROR;
 }
 
 svn_error_t *
-sbox_wc_switch(svn_test__sandbox_t *b, const char *url)
+sbox_wc_switch(svn_test__sandbox_t *b,
+               const char *path,
+               const char *url,
+               svn_depth_t depth)
 {
   svn_client_ctx_t *ctx;
   svn_revnum_t result_rev;
@@ -353,8 +357,8 @@ sbox_wc_switch(svn_test__sandbox_t *b, c
   url = apr_pstrcat(b->pool, b->repos_url, url, (char*)NULL);
   SVN_ERR(svn_client_create_context2(&ctx, NULL, b->pool));
   ctx->wc_ctx = b->wc_ctx;
-  return svn_client_switch3(&result_rev, sbox_wc_path(b, ""), url,
-                            &head_rev, &head_rev, svn_depth_infinity,
+  return svn_client_switch3(&result_rev, sbox_wc_path(b, path), url,
+                            &head_rev, &head_rev, depth,
                             FALSE /* depth_is_sticky */,
                             TRUE /* ignore_externals */,
                             FALSE /* allow_unver_obstructions */,

Modified: subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.h
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.h?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.h (original)
+++ subversion/branches/master-passphrase/subversion/tests/libsvn_wc/utils.h Fri May 10 14:58:47 2013
@@ -134,10 +134,14 @@ svn_error_t *
 sbox_wc_update_depth(svn_test__sandbox_t *b,
                      const char *path,
                      svn_revnum_t revnum,
-                     svn_depth_t depth);
+                     svn_depth_t depth,
+                     svn_boolean_t sticky);
 
 svn_error_t *
-sbox_wc_switch(svn_test__sandbox_t *b, const char *url);
+sbox_wc_switch(svn_test__sandbox_t *b,
+               const char *path,
+               const char *url,
+               svn_depth_t depth);
 
 /* */
 svn_error_t *

Modified: subversion/branches/master-passphrase/subversion/tests/libsvn_wc/wc-queries-test.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/subversion/tests/libsvn_wc/wc-queries-test.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/subversion/tests/libsvn_wc/wc-queries-test.c (original)
+++ subversion/branches/master-passphrase/subversion/tests/libsvn_wc/wc-queries-test.c Fri May 10 14:58:47 2013
@@ -32,6 +32,17 @@
 #ifdef SVN_SQLITE_INLINE
 /* Include sqlite3 inline, making all symbols private. */
   #define SQLITE_API static
+  #ifdef __APPLE__
+    #include <Availability.h>
+    #if __MAC_OS_X_VERSION_MIN_REQUIRED < 1060
+      /* <libkern/OSAtomic.h> is included on OS X by sqlite3.c, and
+         on old systems (Leopard or older), it cannot be compiled
+         with -std=c89 because it uses inline. This is a work-around. */
+      #define inline __inline__
+      #include <libkern/OSAtomic.h>
+      #undef inline
+    #endif
+  #endif
   #include <sqlite3.c>
 #else
   #include <sqlite3.h>

Modified: subversion/branches/master-passphrase/subversion/tests/svn_test_main.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/subversion/tests/svn_test_main.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/subversion/tests/svn_test_main.c (original)
+++ subversion/branches/master-passphrase/subversion/tests/svn_test_main.c Fri May 10 14:58:47 2013
@@ -27,6 +27,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <setjmp.h>
+#ifdef WIN32
+#include <crtdbg.h>
+#endif
 
 #include <apr_pools.h>
 #include <apr_general.h>
@@ -41,8 +44,10 @@
 #include "svn_io.h"
 #include "svn_path.h"
 #include "svn_ctype.h"
-#include "svn_private_config.h"
 
+#include "private/svn_cmdline_private.h"
+
+#include "svn_private_config.h"
 
 /* Some Subversion test programs may want to parse options in the
    argument list, so we remember it here. */
@@ -68,7 +73,8 @@ enum svn_test_mode_t mode_filter = svn_t
 
 /* Option parsing enums and structures */
 enum {
-  cleanup_opt = SVN_OPT_FIRST_LONGOPT_ID,
+  help_opt = SVN_OPT_FIRST_LONGOPT_ID,
+  cleanup_opt,
   fstype_opt,
   list_opt,
   verbose_opt,
@@ -82,6 +88,8 @@ enum {
 
 static const apr_getopt_option_t cl_options[] =
 {
+  {"help",          help_opt, 0,
+                    N_("display this help")},
   {"cleanup",       cleanup_opt, 0,
                     N_("remove test directories after success")},
   {"config-file",   config_opt, 1,
@@ -92,11 +100,11 @@ static const apr_getopt_option_t cl_opti
                     N_("lists all the tests with their short description")},
   {"mode-filter",   mode_filter_opt, 1,
                     N_("only run/list tests with expected mode ARG = PASS, "
-                       "XFAIL, SKIP, or ALL (default)\n")},
+                       "XFAIL, SKIP, or ALL (default)")},
   {"verbose",       verbose_opt, 0,
                     N_("print extra information")},
   {"server-minor-version", server_minor_version_opt, 1,
-                    N_("set the minor version for the server ('3', '4',\n"
+                    N_("set the minor version for the server ('3', '4', "
                        "'5', or '6')")},
   {"quiet",         quiet_opt, 0,
                     N_("print only unexpected results")},
@@ -338,6 +346,26 @@ do_test_num(const char *progname,
 }
 
 
+static void help(const char *progname, apr_pool_t *pool)
+{
+  int i;
+
+  svn_error_clear(svn_cmdline_fprintf(stdout, pool,
+                                      _("usage: %s [options] [test-numbers]\n"
+                                      "\n"
+                                      "Valid options:\n"),
+                                      progname));
+  for (i = 0; cl_options[i].name && cl_options[i].optch; i++)
+    {
+      const char *optstr;
+
+      svn_opt_format_option(&optstr, cl_options + i, TRUE, pool);
+      svn_error_clear(svn_cmdline_fprintf(stdout, pool, "  %s\n", optstr));
+    }
+  svn_error_clear(svn_cmdline_fprintf(stdout, pool, "\n"));
+}
+
+
 /* Standard svn test program */
 int
 main(int argc, const char *argv[])
@@ -395,6 +423,27 @@ main(int argc, const char *argv[])
         prog_name = argv[0];
     }
 
+#ifdef WIN32
+#if _MSC_VER >= 1400
+  /* ### This should work for VC++ 2002 (=1300) and later */
+  /* Show the abort message on STDERR instead of a dialog to allow
+     scripts (e.g. our testsuite) to continue after an abort without
+     user intervention. Allow overriding for easier debugging. */
+  if (!getenv("SVN_CMDLINE_USE_DIALOG_FOR_ABORT"))
+    {
+      /* In release mode: Redirect abort() errors to stderr */
+      _set_error_mode(_OUT_TO_STDERR);
+
+      /* In _DEBUG mode: Redirect all debug output (E.g. assert() to stderr.
+         (Ignored in releas builds) */
+      _CrtSetReportFile( _CRT_ASSERT, _CRTDBG_FILE_STDERR);
+      _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE | _CRTDBG_MODE_DEBUG);
+      _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_FILE | _CRTDBG_MODE_DEBUG);
+      _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_FILE | _CRTDBG_MODE_DEBUG);
+    }
+#endif /* _MSC_VER >= 1400 */
+#endif
+
   if (err)
     return svn_cmdline_handle_exit_error(err, pool, prog_name);
   while (1)
@@ -414,6 +463,9 @@ main(int argc, const char *argv[])
         }
 
       switch (opt_id) {
+        case help_opt:
+          help(prog_name, pool);
+          exit(0);
         case cleanup_opt:
           cleanup_mode = TRUE;
           break;

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/bb-openbsd/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/bb-openbsd/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/bb-openbsd/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/bb-openbsd/svnclean.sh Fri May 10 14:58:47 2013
@@ -24,7 +24,7 @@ set -x
 
 branch="$(basename $(svn info . | grep ^URL  | cut -d' ' -f2))"
 (test -h ../svn-trunk || ln -s build ../svn-trunk)
-for i in 6 7; do
+for i in 6 7 8 9 10; do
   (test -h ../svn-1.${i}.x || ln -s build ../svn-1.${i}.x)
 done
 svn update ../../unix-build

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/centos/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/centos/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/centos/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/centos/svnclean.sh Fri May 10 14:58:47 2013
@@ -27,6 +27,6 @@ echo "========= unmount RAM disc"
 test -e ../unmount-ramdrive && ../unmount-ramdrive
 
 echo "========= make extraclean"
-test -e Makefile && (make extraclean || exit $?)
+test -e Makefile && { make extraclean || exit $?; }
 
 exit 0

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/i686-debian-sarge1/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/i686-debian-sarge1/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/i686-debian-sarge1/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/i686-debian-sarge1/svnclean.sh Fri May 10 14:58:47 2013
@@ -27,6 +27,6 @@ echo "========= unmount RAM disc"
 test -e ../unmount-ramdrive && ../unmount-ramdrive
 
 echo "========= make extraclean"
-test -e Makefile && (make extraclean || exit $?)
+test -e Makefile && { make extraclean || exit $?; }
 
 exit 0

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnclean.sh Fri May 10 14:58:47 2013
@@ -23,7 +23,7 @@
 # ../unmount_ramd.sh
 
 echo "========= make extraclean"
-test -e Makefile && (make extraclean || exit $?)
+test -e Makefile && { make extraclean || exit $?; }
 rm -rf ../build/*
 rm -rf .svn
 rm -rf .buildbot-sourcedata

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnclean.sh Fri May 10 14:58:47 2013
@@ -23,7 +23,7 @@
 # ../unmount_ramd.sh
 
 echo "========= make extraclean"
-test -e Makefile && (make extraclean || exit $?)
+test -e Makefile && { make extraclean || exit $?; }
 rm -rf ../build/*
 rm -rf .svn
 rm -rf .buildbot-sourcedata

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/ubuntu-x64/svnclean.sh
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/ubuntu-x64/svnclean.sh?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/ubuntu-x64/svnclean.sh (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/ubuntu-x64/svnclean.sh Fri May 10 14:58:47 2013
@@ -24,6 +24,6 @@ set -x
 
 echo "========= make extraclean"
 cd build
-test -e Makefile && (make extraclean || exit $?)
+test -e Makefile && { make extraclean || exit $?; }
 
 exit 0

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-bindings.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-bindings.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-bindings.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-bindings.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build-bindings.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build-bindings.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build-bindings.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build-bindings.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -30,7 +30,7 @@ IF ERRORLEVEL 1 (
 )
 
 msbuild subversion_vcnet.sln /p:Configuration=Debug /p:Platform=win32 /t:__JAVAHL__ /t:__JAVAHL_TESTS__
-IF ERRORLEVEL 1 EXIT /B 1 
+IF ERRORLEVEL 1 EXIT /B 1
 
 msbuild subversion_vcnet.sln /p:Configuration=Release /p:Platform=win32 /t:__SWIG_PYTHON__ /t:__SWIG_PERL__
-IF ERRORLEVEL 1 EXIT /B 1 
+IF ERRORLEVEL 1 EXIT /B 1

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-build.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-cleanup.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-cleanup.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-cleanup.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-cleanup.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-template.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-template.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-template.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-template.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-test.cmd
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-test.cmd?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-test.cmd (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-SharpSvn/svntest-test.cmd Fri May 10 14:58:47 2013
@@ -7,9 +7,9 @@ REM   regarding copyright ownership.  Th
 REM   to you under the Apache License, Version 2.0 (the
 REM   "License"); you may not use this file except in compliance
 REM   with the License.  You may obtain a copy of the License at
-REM  
+REM
 REM     http://www.apache.org/licenses/LICENSE-2.0
-REM  
+REM
 REM   Unless required by applicable law or agreed to in writing,
 REM   software distributed under the License is distributed on an
 REM   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/config.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/config.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/config.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/config.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/do_all.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/do_all.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/do_all.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/do_all.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnbuild.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnbuild.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnbuild.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnbuild.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svncheck.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svncheck.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svncheck.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svncheck.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -34,7 +34,7 @@ EXIT 3
 
 :ra_local
 time /T
-python win-tests.py %TEST_DIR%\%FS_TYPE% -f %FS_TYPE% -c -r 
+python win-tests.py %TEST_DIR%\%FS_TYPE% -f %FS_TYPE% -c -r
 if ERRORLEVEL 1 set ERR=1
 time /T
 echo.

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnclean.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnclean.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnclean.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnclean.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnlog.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnlog.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnlog.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/win32-xp-VS2005/svnlog.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnbuild.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnbuild.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnbuild.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnbuild.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svncheck.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svncheck.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svncheck.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svncheck.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -32,7 +32,7 @@ echo Unknown ra method '%RA_TYPE%'
 EXIT 3
 
 :ra_local
-python win-tests.py %TEST_DIR% -f %FS_TYPE% -c -r 
+python win-tests.py %TEST_DIR% -f %FS_TYPE% -c -r
 if ERRORLEVEL 1 set ERR=1
 EXIT %ERR%
 

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnclean.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnclean.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnclean.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnclean.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnlog.bat
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnlog.bat?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnlog.bat (original)
+++ subversion/branches/master-passphrase/tools/buildbot/slaves/xp-vc60-ia32/svnlog.bat Fri May 10 14:58:47 2013
@@ -5,9 +5,9 @@ REM     regarding copyright ownership.  
 REM     to you under the Apache License, Version 2.0 (the
 REM     "License"); you may not use this file except in compliance
 REM     with the License.  You may obtain a copy of the License at
-REM    
+REM
 REM       http://www.apache.org/licenses/LICENSE-2.0
-REM    
+REM
 REM     Unless required by applicable law or agreed to in writing,
 REM     software distributed under the License is distributed on an
 REM     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

Modified: subversion/branches/master-passphrase/tools/client-side/svn-bench/client_errors.h
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/client-side/svn-bench/client_errors.h?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/client-side/svn-bench/client_errors.h (original)
+++ subversion/branches/master-passphrase/tools/client-side/svn-bench/client_errors.h Fri May 10 14:58:47 2013
@@ -43,6 +43,8 @@ extern "C" {
 
 #if defined(SVN_ERROR_BUILD_ARRAY)
 
+#error "Need to update err_defn for r1464679 and un-typo 'CDMLINE'"
+
 #define SVN_ERROR_START \
         static const err_defn error_table[] = { \
           { SVN_ERR_CDMLINE__WARNING, "Warning" },

Modified: subversion/branches/master-passphrase/tools/client-side/svn-bench/null-export-cmd.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/client-side/svn-bench/null-export-cmd.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/client-side/svn-bench/null-export-cmd.c (original)
+++ subversion/branches/master-passphrase/tools/client-side/svn-bench/null-export-cmd.c Fri May 10 14:58:47 2013
@@ -141,7 +141,7 @@ change_file_prop(void *file_baton,
   edit_baton_t *eb = file_baton;
   eb->prop_count++;
   eb->prop_byte_count += value->len;
-  
+
   return SVN_NO_ERROR;
 }
 
@@ -250,13 +250,15 @@ bench_null_export(svn_revnum_t *result_r
                                                       pool));
 
           /* Manufacture a basic 'report' to the update reporter. */
-          SVN_ERR(svn_ra_do_update2(ra_session,
+          SVN_ERR(svn_ra_do_update3(ra_session,
                                     &reporter, &report_baton,
                                     loc->rev,
                                     "", /* no sub-target */
                                     depth,
                                     FALSE, /* don't want copyfrom-args */
-                                    export_editor, edit_baton, pool));
+                                    FALSE, /* don't want ignore_ancestry */
+                                    export_editor, edit_baton,
+                                    pool, pool));
 
           SVN_ERR(reporter->set_path(report_baton, "", loc->rev,
                                      /* Depth is irrelevant, as we're

Modified: subversion/branches/master-passphrase/tools/client-side/svn-bench/null-log-cmd.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/client-side/svn-bench/null-log-cmd.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/client-side/svn-bench/null-log-cmd.c (original)
+++ subversion/branches/master-passphrase/tools/client-side/svn-bench/null-log-cmd.c Fri May 10 14:58:47 2013
@@ -95,7 +95,7 @@ log_entry_receiver(void *baton,
   svn_compat_log_revprops_out(&author, &date, &message, log_entry->revprops);
   if (log_entry->revision == 0 && message == NULL)
     return SVN_NO_ERROR;
-  
+
   lb->revisions++;
   if (lb->merge_depth)
     lb->merged_revs++;

Modified: subversion/branches/master-passphrase/tools/client-side/svn-bench/svn-bench.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/client-side/svn-bench/svn-bench.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/client-side/svn-bench/svn-bench.c (original)
+++ subversion/branches/master-passphrase/tools/client-side/svn-bench/svn-bench.c Fri May 10 14:58:47 2013
@@ -253,7 +253,7 @@ const svn_opt_subcommand_desc2_t svn_cl_
      "  affected paths for that revision were explicitly requested.  Logs\n"
      "  follow copy history by default.  Use --stop-on-copy to disable this\n"
      "  behavior, which can be useful for determining branchpoints.\n"),
-    {'r', 'q', 'v', 'g', 'c', opt_targets, opt_stop_on_copy, 
+    {'r', 'q', 'v', 'g', 'c', opt_targets, opt_stop_on_copy,
      'l', opt_with_all_revprops, opt_with_no_revprops, opt_with_revprop,
      'x',},
     {{opt_with_revprop, N_("retrieve revision property ARG")},
@@ -363,7 +363,7 @@ sub_main(int argc, const char *argv[], a
   /* No args?  Show usage. */
   if (argc <= 1)
     {
-      svn_cl__help(NULL, NULL, pool);
+      SVN_INT_ERR(svn_cl__help(NULL, NULL, pool));
       return EXIT_FAILURE;
     }
 
@@ -383,7 +383,7 @@ sub_main(int argc, const char *argv[], a
         break;
       else if (apr_err)
         {
-          svn_cl__help(NULL, NULL, pool);
+          SVN_INT_ERR(svn_cl__help(NULL, NULL, pool));
           return EXIT_FAILURE;
         }
 
@@ -668,7 +668,7 @@ sub_main(int argc, const char *argv[], a
               svn_error_clear
                 (svn_cmdline_fprintf(stderr, pool,
                                      _("Subcommand argument required\n")));
-              svn_cl__help(NULL, NULL, pool);
+              SVN_INT_ERR(svn_cl__help(NULL, NULL, pool));
               return EXIT_FAILURE;
             }
         }
@@ -686,7 +686,7 @@ sub_main(int argc, const char *argv[], a
                 (svn_cmdline_fprintf(stderr, pool,
                                      _("Unknown subcommand: '%s'\n"),
                                      first_arg_utf8));
-              svn_cl__help(NULL, NULL, pool);
+              SVN_INT_ERR(svn_cl__help(NULL, NULL, pool));
               return EXIT_FAILURE;
             }
         }
@@ -713,7 +713,7 @@ sub_main(int argc, const char *argv[], a
                                           subcommand, pool);
           svn_opt_format_option(&optstr, badopt, FALSE, pool);
           if (subcommand->name[0] == '-')
-            svn_cl__help(NULL, NULL, pool);
+            SVN_INT_ERR(svn_cl__help(NULL, NULL, pool));
           else
             svn_error_clear
               (svn_cmdline_fprintf

Modified: subversion/branches/master-passphrase/tools/dev/aprerr.txt
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/dev/aprerr.txt?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/dev/aprerr.txt (original)
+++ subversion/branches/master-passphrase/tools/dev/aprerr.txt Fri May 10 14:58:47 2013
@@ -1,3 +1,4 @@
+# This file is used by which-error.py and gen_base.py:write_errno_table()
 APR_SUCCESS = 0
 SOCBASEERR = 10000
 SOCEPERM = 10001

Modified: subversion/branches/master-passphrase/tools/dev/benchmarks/suite1/benchmark.py
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/dev/benchmarks/suite1/benchmark.py?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/dev/benchmarks/suite1/benchmark.py (original)
+++ subversion/branches/master-passphrase/tools/dev/benchmarks/suite1/benchmark.py Fri May 10 14:58:47 2013
@@ -20,10 +20,10 @@
 """Usage: benchmark.py run|list|compare|show|chart <selection> ...
 
 SELECTING TIMINGS -- B@R,LxS
- 
+
 In the subcommands below, a timings selection consists of a string with up to
 four elements:
-  <branch>@<revision>,<levels>x<spread> 
+  <branch>@<revision>,<levels>x<spread>
 abbreviated as:
   B@R,LxS
 
@@ -214,9 +214,9 @@ def next_unique_basename(prefix):
 
 si_units = [
     (1000 ** 5, 'P'),
-    (1000 ** 4, 'T'), 
-    (1000 ** 3, 'G'), 
-    (1000 ** 2, 'M'), 
+    (1000 ** 4, 'T'),
+    (1000 ** 3, 'G'),
+    (1000 ** 2, 'M'),
     (1000 ** 1, 'K'),
     (1000 ** 0, ''),
     ]
@@ -308,7 +308,7 @@ def parse_timings_selections(db, *args):
       run_kinds.append(run_kind)
 
   return run_kinds
-  
+
 def parse_one_timing_selection(db, *args):
   run_kinds = parse_timings_selections(db, *args)
   if len(run_kinds) != 1:
@@ -433,7 +433,7 @@ class Run:
       kind_id = c.lastrowid
 
     self.started = time_str()
-    
+
     c.execute("""
         INSERT INTO run
           (batch_id, run_kind_id, started)
@@ -595,7 +595,7 @@ class TimingQuery:
     for command_name in self.get_sorted_command_names():
       self.timings[command_name] = self.get_command_timings(command_name)
     return self.timings
-      
+
 
 # ------------------------------------------------------------ run tests
 
@@ -890,10 +890,10 @@ def perform_run(batch, run_kind,
 
 # ---------------------------------------------------------------------
 
-    
+
 def cmdline_run(db, options, run_kind_str, N=1):
   run_kind = parse_one_timing_selection(db, run_kind_str)
-    
+
   N = int(N)
 
   print 'Hi, going to run a Subversion benchmark series of %d runs...' % N
@@ -938,7 +938,7 @@ def cmdline_list(db, options, *args):
     print 'I found:'
 
     d = TimingQuery(db, run_kind)
-    
+
     cmd_names = d.get_sorted_command_names()
     if cmd_names:
       print '\n%d command names:\n ' % len(cmd_names), '\n  '.join(cmd_names)
@@ -1097,7 +1097,7 @@ def cmdline_chart_compare(db, options, *
     chart_path = 'compare_' + '_'.join(
       [ filesystem_safe_string(l) for l in labels ]
       ) + '.svg'
-                  
+
   N = len(command_names)
   M = len(timing_sets) - 1
   if M < 2:
@@ -1238,7 +1238,7 @@ class IndentedHelpFormatterWithNL(optpar
         subsequent_indent=indent)
       for bit in bits]
     result = "\n".join(formatted_bits) + "\n"
-    return result 
+    return result
 
 if __name__ == '__main__':
   parser = optparse.OptionParser(formatter=IndentedHelpFormatterWithNL())

Modified: subversion/branches/master-passphrase/tools/dev/fsfs-access-map.c
URL: http://svn.apache.org/viewvc/subversion/branches/master-passphrase/tools/dev/fsfs-access-map.c?rev=1481041&r1=1481040&r2=1481041&view=diff
==============================================================================
--- subversion/branches/master-passphrase/tools/dev/fsfs-access-map.c (original)
+++ subversion/branches/master-passphrase/tools/dev/fsfs-access-map.c Fri May 10 14:58:47 2013
@@ -219,7 +219,7 @@ read_file(int handle, apr_int64_t count)
   if (handle_info)
     {
       /* known file handle -> expand current read sequence */
-      
+
       handle_info->last_read_size += count;
       handle_info->file->read_count++;
       handle_info->file->read_size += count;
@@ -239,7 +239,7 @@ seek_file(int handle, apr_int64_t locati
       apr_size_t cluster = (apr_size_t)(location / cluster_size);
 
       store_read_info(handle_info);
-      
+
       handle_info->last_read_size = 0;
       handle_info->last_read_start = location;
       handle_info->file->seek_count++;
@@ -278,7 +278,7 @@ parse_line(svn_stringbuf_t *line)
 
   if (func_end == NULL || return_value == NULL)
     return;
-  
+
   first_param_end = strchr(func_end, ',');
   if (first_param_end == NULL)
     first_param_end = strchr(func_end, ')');
@@ -293,14 +293,14 @@ parse_line(svn_stringbuf_t *line)
   /* (try to) convert the return value into an integer.
    * If that fails, continue anyway as defaulting to 0 will be safe for us. */
   svn_error_clear(svn_cstring_atoi64(&func_return, return_value));
-  
+
   /* process those operations that we care about */
   if (strcmp(line->data, "open") == 0)
     {
       /* remove double quotes from file name parameter */
       *func_end++ = 0;
       *--first_param_end = 0;
-      
+
       open_file(func_end, (int)func_return);
     }
   else if (strcmp(line->data, "read") == 0)
@@ -592,14 +592,14 @@ print_stats(apr_pool_t *pool)
   apr_int64_t clusters_read = 0;
   apr_int64_t unique_clusters_read = 0;
   apr_int64_t uncached_seek_count = 0;
-  
+
   apr_hash_index_t *hi;
   for (hi = apr_hash_first(pool, files); hi; hi = apr_hash_next(hi))
     {
       const char *name = NULL;
       apr_ssize_t len = 0;
       file_stats_t *file = NULL;
-      
+
       apr_hash_this(hi, (const void **)&name, &len, (void**)&file);
 
       open_count += file->open_count;
@@ -641,7 +641,7 @@ int main(int argc, const char *argv[])
 {
   apr_pool_t *pool = NULL;
   apr_file_t *file = NULL;
-  
+
   apr_initialize();
   atexit(apr_terminate);
 
@@ -661,7 +661,7 @@ int main(int argc, const char *argv[])
   apr_file_close(file);
 
   print_stats(pool);
-  
+
   apr_file_open(&file, "access.bmp",
                 APR_WRITE | APR_CREATE | APR_TRUNCATE | APR_BUFFERED,
                 APR_OS_DEFAULT, pool);