You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2010/10/30 16:20:18 UTC

svn commit: r1029078 [5/5] - in /subversion/branches/performance: ./ build/ac-macros/ subversion/bindings/javahl/native/ subversion/bindings/javahl/src/org/apache/subversion/javahl/ subversion/bindings/javahl/src/org/tigris/subversion/javahl/ subversio...

Modified: subversion/branches/performance/subversion/tests/libsvn_wc/entries-compat.c
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/tests/libsvn_wc/entries-compat.c?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/subversion/tests/libsvn_wc/entries-compat.c (original)
+++ subversion/branches/performance/subversion/tests/libsvn_wc/entries-compat.c Sat Oct 30 14:20:17 2010
@@ -97,27 +97,27 @@ static const char * const TESTING_DATA =
   "  null, null, 'dir', '()', 'infinity', null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'A', 0, '', null, null, 1, 'normal',"
+  "  1, 'A', 0, '', 1, 'A', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  10, null, null, null);"
   "insert into nodes values ("
-  "  1, 'B', 0, '', null, null, null, 'excluded',"
+  "  1, 'B', 0, '', 1, 'B', null, 'excluded',"
   "  null, null, 'symlink', null, null, null, null, null, null, null,"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'C', 0, '', null, null, null, 'absent',"
+  "  1, 'C', 0, '', 1, 'C', null, 'absent',"
   "  null, null, 'unknown', null, null, null, null, null, null, null,"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'D', 0, '', null, null, null, 'not-present',"
+  "  1, 'D', 0, '', 1, 'D', null, 'not-present',"
   "  null, null, 'unknown', null, null, null, null, null, null, null,"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'E', 0, '', null, null, null, 'incomplete',"
+  "  1, 'E', 0, '', 1, 'E', null, 'incomplete',"
   "  null, null, 'unknown', null, null, null, null, null, null, null,"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'F', 0, '', null, null, 1, 'normal',"
+  "  1, 'F', 0, '', 1, 'F', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  15, null, null, null);"
   "insert into nodes values ("
@@ -125,51 +125,51 @@ static const char * const TESTING_DATA =
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 2, " TIME_2s ", '" AUTHOR_2 "',"
   "  15, null, null, null);"
   "insert into nodes values ("
-  "  1, 'H', 0, '', null, null, 1, 'normal',"
+  "  1, 'H', 0, '', 1, 'H', 1, 'normal',"
   "  null, null, 'symlink', '()', null, null, 'H-target', 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'I', 0, '', null, null, 1, 'normal',"
+  "  1, 'I', 0, '', 1, 'I', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J', 0, '', null, null, 1, 'normal',"
+  "  1, 'J', 0, '', 1, 'J', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-e', 0, 'J', null, null, 1, 'normal',"
+  "  1, 'J/J-e', 0, 'J', 1, 'J/J-e', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-e/J-e-a', 0, 'J/J-e', null, null, 1, 'normal',"
+  "  1, 'J/J-e/J-e-a', 0, 'J/J-e', 1, 'J/J-e/J-e-a', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  15, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-e/J-e-b', 0, 'J/J-e', null, null, 1, 'normal',"
+  "  1, 'J/J-e/J-e-b', 0, 'J/J-e', 1, 'J/J-e/J-e-b', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-e/J-e-b/Jeba', 0, 'J/J-e/J-e-b', null, null, 1, 'normal',"
+  "  1, 'J/J-e/J-e-b/Jeba', 0, 'J/J-e/J-e-b', 1, 'J/J-e/J-e-b/Jeba', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  15, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-f', 0, 'J', null, null, 1, 'normal',"
+  "  1, 'J/J-f', 0, 'J', 1, 'J/J-f', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'J/J-f/J-f-a', 0, 'J/J-f', null, null, 1, 'normal',"
+  "  1, 'J/J-f/J-f-a', 0, 'J/J-f', 1, 'J/J-f/J-f-a', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'K', 0, '', null, null, 1, 'normal',"
+  "  1, 'K', 0, '', 1, 'K', 1, 'normal',"
   "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  null, null, null, null);"
   "insert into nodes values ("
-  "  1, 'K/K-a', 0, 'K', null, null, 1, 'normal',"
+  "  1, 'K/K-a', 0, 'K', 1, 'K/K-a', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  15, null, null, null);"
   "insert into nodes values ("
-  "  1, 'K/K-b', 0, 'K', null, null, 1, 'normal',"
+  "  1, 'K/K-b', 0, 'K', 1, 'K/K-b', 1, 'normal',"
   "  null, null, 'file', '()', null, '$md5 $" MD5_1 "', null, 1, " TIME_1s ", '" AUTHOR_1 "',"
   "  15, null, null, null);"
   ""
@@ -265,11 +265,11 @@ static const char * const TESTING_DATA =
    "'" I_TC_DATA "', null, null, null, null);"
    "  "
    "insert into nodes values ("
-   "  1, 'M', 0, '', null, null, 1, 'normal', "
+   "  1, 'M', 0, '', 1, 'M', 1, 'normal', "
    "  null, null, 'dir', '()', null, null, null, 1, " TIME_1s ", '" AUTHOR_1 "', "
    "  null, null, null, null);"
    "insert into nodes values ("
-   "  1, 'M/M-a', 0, 'M', null, null, 1, 'not-present', "
+   "  1, 'M/M-a', 0, 'M', 1, 'M/M-a', 1, 'not-present', "
    "  null, null, 'file', '()', null, null, null, 1, null, null, "
    "  null, null, null, null);"
    );

Modified: subversion/branches/performance/subversion/tests/libsvn_wc/op-depth-test.c
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/tests/libsvn_wc/op-depth-test.c?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/subversion/tests/libsvn_wc/op-depth-test.c (original)
+++ subversion/branches/performance/subversion/tests/libsvn_wc/op-depth-test.c Sat Oct 30 14:20:17 2010
@@ -177,6 +177,15 @@ wc_revert(wc_baton_t *b, const char *pat
                         b->pool);
 }
 
+static svn_error_t *
+wc_delete(wc_baton_t *b, const char *path)
+{
+  const char *abspath = wc_path(b, path);
+
+  return svn_wc_delete4(b->wc_ctx, abspath, FALSE, TRUE, NULL, NULL, NULL, NULL,
+                        b->pool);
+}
+
 /* Create the Greek tree on disk in the WC, and commit it. */
 static svn_error_t *
 add_and_commit_greek_tree(wc_baton_t *b)
@@ -274,6 +283,12 @@ typedef struct {
  * Append an error message to BATON->errors if they differ or are not both
  * present.
  *
+ * If the ACTUAL row has field values that should have been elided
+ * (because they match the parent row), then do so now.  We want to ignore
+ * any such lack of elision, for the purposes of these tests, because the
+ * method of copying in use (at the time this tweak is introduced) does
+ * calculate these values itself, it simply copies from the source rows.
+ *
  * Implements svn_hash_diff_func_t. */
 static svn_error_t *
 compare_nodes_rows(const void *key, apr_ssize_t klen,
@@ -284,6 +299,30 @@ compare_nodes_rows(const void *key, apr_
   nodes_row_t *expected = apr_hash_get(b->expected_hash, key, klen);
   nodes_row_t *actual = apr_hash_get(b->actual_hash, key, klen);
 
+  /* If the ACTUAL row has field values that should have been elided
+   * (because they match the parent row), then do so now. */
+  if (actual && actual->op_depth > 0 && actual->repo_relpath)
+    {
+      const char *parent_relpath, *name, *parent_key;
+      nodes_row_t *parent_actual;
+
+      svn_relpath_split(&parent_relpath, &name, actual->local_relpath,
+                        b->scratch_pool);
+      parent_key = apr_psprintf(b->scratch_pool, "%d %s",
+                                actual->op_depth, parent_relpath);
+      parent_actual = apr_hash_get(b->actual_hash, parent_key,
+                                   APR_HASH_KEY_STRING);
+      if (parent_actual && parent_actual > 0 && parent_actual->repo_relpath
+          && strcmp(actual->repo_relpath,
+                    svn_relpath_join(parent_actual->repo_relpath, name,
+                                     b->scratch_pool)) == 0
+          && actual->repo_revnum == parent_actual->repo_revnum)
+        {
+          actual->repo_relpath = NULL;
+          actual->repo_revnum = SVN_INVALID_REVNUM;
+        }
+    }
+
   if (! expected)
     {
       b->errors = svn_error_createf(
@@ -378,26 +417,24 @@ check_db_rows(wc_baton_t *b,
 /* ---------------------------------------------------------------------- */
 /* The test functions */
 
-/* Check that all kinds of WC-to-WC copies give correct op_depth results. */
+/* Check that all kinds of WC-to-WC copies give correct op_depth results:
+ * create a Greek tree, make copies in it, and check the resulting DB rows. */
 static svn_error_t *
 wc_wc_copies(wc_baton_t *b)
 {
+  const char source_everything[]  = "A/B";
 
-  SVN_ERR(svn_wc_context_create(&(*b).wc_ctx, NULL, b->pool, b->pool));
-
-  SVN_ERR(add_and_commit_greek_tree(b));
-
-#define source_everything  "A/B"
+  const char source_base_file[]   = "A/B/lambda";
+  const char source_base_dir[]    = "A/B/E";
 
-#define source_base_file   "A/B/lambda"
-#define source_base_dir    "A/B/E"
+  const char source_added_file[]  = "A/B/file-added";
+  const char source_added_dir[]   = "A/B/D-added";
+  const char source_added_dir2[]  = "A/B/D-added/D2";
 
-#define source_added_file  "A/B/file-added"
-#define source_added_dir   "A/B/D-added"
-#define source_added_dir2  "A/B/D-added/D2"
+  const char source_copied_file[] = "A/B/lambda-copied";
+  const char source_copied_dir[]  = "A/B/E-copied";
 
-#define source_copied_file "A/B/lambda-copied"
-#define source_copied_dir  "A/B/E-copied"
+  SVN_ERR(add_and_commit_greek_tree(b));
 
   /* Create the various kinds of source node which will be copied */
 
@@ -492,7 +529,11 @@ wc_wc_copies(wc_baton_t *b)
     /* Perform each subtest in turn. */
     for (subtest = subtests; subtest->from_path; subtest++)
       {
-        SVN_ERR(wc_copy(b, subtest->from_path, subtest->to_path));
+        SVN_ERR(svn_wc_copy3(b->wc_ctx,
+                             wc_path(b, subtest->from_path),
+                             wc_path(b, subtest->to_path),
+                             FALSE /* metadata_only */,
+                             NULL, NULL, NULL, NULL, b->pool));
         SVN_ERR(check_db_rows(b, subtest->to_path, subtest->expected));
       }
   }
@@ -509,6 +550,7 @@ test_wc_wc_copies(const svn_test_opts_t 
   b.pool = pool;
   SVN_ERR(svn_test__create_repos_and_wc(&b.repos_url, &b.wc_abspath,
                                         "wc_wc_copies", opts, pool));
+  SVN_ERR(svn_wc_context_create(&b.wc_ctx, NULL, pool, pool));
 
   return wc_wc_copies(&b);
 }
@@ -522,6 +564,7 @@ test_reverts(const svn_test_opts_t *opts
   b.pool = pool;
   SVN_ERR(svn_test__create_repos_and_wc(&b.repos_url, &b.wc_abspath,
                                         "reverts", opts, pool));
+  SVN_ERR(svn_wc_context_create(&b.wc_ctx, NULL, pool, pool));
 
   SVN_ERR(wc_wc_copies(&b));
 
@@ -535,6 +578,108 @@ test_reverts(const svn_test_opts_t *opts
   return SVN_NO_ERROR;
 }
 
+static svn_error_t *
+test_deletes(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  wc_baton_t b;
+
+  b.pool = pool;
+  SVN_ERR(svn_test__create_repos_and_wc(&b.repos_url, &b.wc_abspath,
+                                        "deletes", opts, pool));
+  SVN_ERR(svn_wc_context_create(&b.wc_ctx, NULL, pool, pool));
+  SVN_ERR(add_and_commit_greek_tree(&b));
+
+  file_write(&b,     "A/B/E/new-file", "New file");
+  SVN_ERR(wc_add(&b, "A/B/E/new-file"));
+  {
+    nodes_row_t rows[] = {
+      { 4, "A/B/E/new-file", "normal", NO_COPY_FROM },
+      { 0 }
+    };
+    SVN_ERR(check_db_rows(&b, "A/B/E/new-file", rows));
+  }
+
+  SVN_ERR(svn_wc_delete4(b.wc_ctx, wc_path(&b, "A/B/E/alpha"),
+                         FALSE, TRUE, NULL, NULL, NULL, NULL, pool));
+  {
+    nodes_row_t rows[] = {
+      { 0, "A/B/E/alpha", "normal",       1, "A/B/E/alpha" },
+      { 4, "A/B/E/alpha", "base-deleted", NO_COPY_FROM },
+      { 0 }
+    };
+    SVN_ERR(check_db_rows(&b, "A/B/E/alpha", rows));
+  }
+
+  SVN_ERR(svn_wc_delete4(b.wc_ctx, wc_path(&b, "A/B/F"),
+                         FALSE, TRUE, NULL, NULL, NULL, NULL, pool));
+  {
+    nodes_row_t rows[] = {
+      { 0, "A/B/F", "normal",       1, "A/B/F" },
+      { 3, "A/B/F", "base-deleted", NO_COPY_FROM },
+      { 0 }
+    };
+    SVN_ERR(check_db_rows(&b, "A/B/F", rows));
+  }
+
+  SVN_ERR(svn_wc_delete4(b.wc_ctx, wc_path(&b, "A/B"),
+                         FALSE, TRUE, NULL, NULL, NULL, NULL, pool));
+  {
+    nodes_row_t rows[] = {
+      { 0, "A/B",         "normal",       1, "A/B",        },
+      { 2, "A/B/lambda",  "base-deleted", NO_COPY_FROM },
+      { 0, "A/B/lambda",  "normal",       1, "A/B/lambda", },
+      { 2, "A/B",         "base-deleted", NO_COPY_FROM },
+      { 0, "A/B/E",       "normal",       1, "A/B/E",      },
+      { 2, "A/B/E",       "base-deleted", NO_COPY_FROM },
+      { 0, "A/B/E/alpha", "normal",       1, "A/B/E/alpha" },
+      { 2, "A/B/E/alpha", "base-deleted", NO_COPY_FROM },
+      { 0, "A/B/E/beta",  "normal",       1, "A/B/E/beta" },
+      { 2, "A/B/E/beta",  "base-deleted", NO_COPY_FROM },
+      { 0, "A/B/F",       "normal",       1, "A/B/F",      },
+      { 2, "A/B/F",       "base-deleted", NO_COPY_FROM },
+      { 0 }
+    };
+    SVN_ERR(check_db_rows(&b, "A/B", rows));
+  }
+
+  return SVN_NO_ERROR;
+}
+
+
+static svn_error_t *
+test_delete_of_copies(const svn_test_opts_t *opts, apr_pool_t *pool)
+{
+  wc_baton_t b;
+
+  b.pool = pool;
+  SVN_ERR(svn_test__create_repos_and_wc(&b.repos_url, &b.wc_abspath,
+                                        "deletes", opts, pool));
+  SVN_ERR(svn_wc_context_create(&b.wc_ctx, NULL, pool, pool));
+  SVN_ERR(add_and_commit_greek_tree(&b));
+
+  SVN_ERR(wc_copy(&b, "A/B", "A/B-copied"));
+  SVN_ERR(wc_delete(&b, "A/B-copied/E"));
+  SVN_ERR(wc_copy(&b, "A/B", "A/B-copied/E"));
+
+  SVN_ERR(svn_wc_delete4(b.wc_ctx, wc_path(&b, "A/B-copied/E/F"),
+                         FALSE, TRUE, NULL, NULL, NULL, NULL, pool));
+  {
+    nodes_row_t rows[] = {
+      { 3, "A/B-copied/E/F", "not-present",       1, "A/B/F" },
+      { 0 }
+    };
+    SVN_ERR(check_db_rows(&b, "A/B-copied/E/F", rows));
+  }
+
+  SVN_ERR(svn_wc_delete4(b.wc_ctx, wc_path(&b, "A/B-copied"),
+                         FALSE, TRUE, NULL, NULL, NULL, NULL, pool));
+  {
+    nodes_row_t rows[] = { { 0 } };
+    SVN_ERR(check_db_rows(&b, "A/B-copied", rows));
+  }
+
+  return SVN_NO_ERROR;
+}
 
 /* ---------------------------------------------------------------------- */
 /* The list of test functions */
@@ -548,5 +693,11 @@ struct svn_test_descriptor_t test_funcs[
     SVN_TEST_OPTS_WIMP(test_reverts,
                        "test_reverts",
                        "needs op_depth"),
+    SVN_TEST_OPTS_WIMP(test_deletes,
+                       "test_deletes",
+                       "needs op_depth"),
+    SVN_TEST_OPTS_WIMP(test_delete_of_copies,
+                       "test_delete_of_copies",
+                       "needs op_depth"),
     SVN_TEST_NULL
   };

Modified: subversion/branches/performance/tools/diff/diff.c
URL: http://svn.apache.org/viewvc/subversion/branches/performance/tools/diff/diff.c?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/tools/diff/diff.c (original)
+++ subversion/branches/performance/tools/diff/diff.c Sat Oct 30 14:20:17 2010
@@ -28,35 +28,55 @@
 #include "svn_pools.h"
 #include "svn_diff.h"
 #include "svn_io.h"
-
+#include "svn_utf.h"
 
 static svn_error_t *
 do_diff(svn_stream_t *ostream,
-        const char *original, const char *modified,
+        const char *original,
+        const char *modified,
         svn_boolean_t *has_changes,
+        svn_diff_file_options_t *options,
+        svn_boolean_t show_c_function,
         apr_pool_t *pool)
 {
   svn_diff_t *diff;
 
-  SVN_ERR(svn_diff_file_diff(&diff, original, modified, pool));
-
+  SVN_ERR(svn_diff_file_diff_2(&diff, original, modified, options, pool));
   *has_changes = svn_diff_contains_diffs(diff);
+  return svn_diff_file_output_unified3(ostream, diff, original, modified,
+                                       NULL, NULL, SVN_APR_LOCALE_CHARSET,
+                                       NULL, show_c_function, pool);
+}
 
-  SVN_ERR(svn_diff_file_output_unified(ostream, diff,
-                                       original, modified,
-                                       NULL, NULL, pool));
-
-  return NULL;
+static void
+print_usage(svn_stream_t *ostream, const char *progname,
+            apr_pool_t *pool)
+{
+  svn_error_clear(svn_stream_printf(ostream, pool,
+     "Usage: %s [OPTIONS] <file1> <file2>\n"
+     "\n"
+     "Display the differences between <file1> and <file2> in unified diff\n"
+     "format.  OPTIONS are diff extensions as described by 'svn help diff'.\n"
+     "Use '--' alone to indicate that no more options follow.\n",
+     progname));
 }
 
-int main(int argc, char *argv[])
+int main(int argc, const char *argv[])
 {
   apr_pool_t *pool;
   svn_stream_t *ostream;
-  int rc;
   svn_error_t *svn_err;
+  svn_boolean_t has_changes;
+  svn_diff_file_options_t *diff_options;
+  apr_array_header_t *options_array;
+  int i;
+  const char *from = NULL;
+  const char *to = NULL;
+  svn_boolean_t show_c_function = FALSE;
+  svn_boolean_t no_more_options = FALSE;
 
   apr_initialize();
+  atexit(apr_terminate);
 
   pool = svn_pool_create(NULL);
 
@@ -64,32 +84,65 @@ int main(int argc, char *argv[])
   if (svn_err)
     {
       svn_handle_error2(svn_err, stdout, FALSE, "diff: ");
-      rc = 2;
+      return 2;
     }
-  else if (argc == 3)
+  
+  options_array = apr_array_make(pool, 0, sizeof(const char *));
+  
+  for (i = 1 ; i < argc ; i++)
     {
-      svn_boolean_t has_changes;
-
-      svn_err = do_diff(ostream, argv[1], argv[2], &has_changes, pool);
-      if (svn_err == NULL)
+      if (!no_more_options && (argv[i][0] == '-'))
         {
-          rc = has_changes ? 1 : 0;
+          /* Special case: '--' means "no more options follow" */
+          if (argv[i][1] == '-' && !argv[i][2])
+            {
+              no_more_options = TRUE;
+              continue;
+            }
+          /* Special case: we need to detect '-p' and handle it specially */
+          if (argv[i][1] == 'p' && !argv[i][2])
+            {
+              show_c_function = TRUE;
+              continue;
+            }
+          APR_ARRAY_PUSH(options_array, const char *) = argv[i];
         }
       else
         {
-          svn_handle_error2(svn_err, stdout, FALSE, "diff: ");
-          rc = 2;
+          if (from == NULL)
+            from = argv[i];
+          else if (to == NULL)
+            to = argv[i];
+          else
+            {
+              print_usage(ostream, argv[0], pool);
+              return 2;
+            }
         }
     }
-  else
+
+  if (!from || !to)
     {
-      svn_error_clear(svn_stream_printf(ostream, pool,
-                                        "Usage: %s <file1> <file2>\n",
-                                        argv[0]));
-      rc = 2;
+      print_usage(ostream, argv[0], pool);
+      return 2;
     }
 
-  apr_terminate();
+  diff_options = svn_diff_file_options_create(pool);
+
+  svn_err = svn_diff_file_options_parse(diff_options, options_array, pool);
+  if (svn_err)
+    {
+      svn_handle_error2(svn_err, stdout, FALSE, "diff: ");
+      return 2;
+    }
+
+  svn_err = do_diff(ostream, from, to, &has_changes,
+                    diff_options, show_c_function, pool);
+  if (svn_err)
+    {
+      svn_handle_error2(svn_err, stdout, FALSE, "diff: ");
+      return 2;
+    }
 
-  return rc;
+  return has_changes ? 1 : 0;
 }

Modified: subversion/branches/performance/tools/hook-scripts/svnperms.conf.example
URL: http://svn.apache.org/viewvc/subversion/branches/performance/tools/hook-scripts/svnperms.conf.example?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/tools/hook-scripts/svnperms.conf.example (original)
+++ subversion/branches/performance/tools/hook-scripts/svnperms.conf.example Sat Oct 30 14:20:17 2010
@@ -9,6 +9,8 @@
 #
 [groups]
 group1 = user1 user2 user3
+group2 = user4 user5
+supergroup = @group1 @group2 user6
 
 #
 # Example repository control, showing allowed syntax.
@@ -20,13 +22,13 @@ group1 = user1 user2 user3
 # - line breaks are accepted
 #
 [example1 groups]
-group2 = user9 user10
+group3 = user9 user10
 
 [example1]
 trunk/.* = *(add,remove,update) @group1,user4,user5(update)
            user6,user7()
 trunk/.* = user8(add,update)
-tags/[^/]+/ = @group2(add)
+tags/[^/]+/ = @group3(add)
 branches/[^/]+/.* = *(add,remove,update)
 
 #

Modified: subversion/branches/performance/tools/hook-scripts/svnperms.py
URL: http://svn.apache.org/viewvc/subversion/branches/performance/tools/hook-scripts/svnperms.py?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/tools/hook-scripts/svnperms.py (original)
+++ subversion/branches/performance/tools/hook-scripts/svnperms.py Sat Oct 30 14:20:17 2010
@@ -128,7 +128,17 @@ class Permission:
 
     def parse_groups(self, groupsiter):
         for option, value in groupsiter:
-            self._group[option] = value.split()
+            groupusers = []
+            for token in value.split():
+                # expand nested groups in place; no forward decls
+                if token[0] == "@":
+                    try:
+                        groupusers.extend(self._group[token[1:]])
+                    except KeyError:
+                        raise Error, "group '%s' not found" % token[1:]
+                else:
+                    groupusers.append(token)
+            self._group[option] = groupusers
 
     def parse_perms(self, permsiter):
         for option, value in permsiter:

Modified: subversion/branches/performance/win-tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/performance/win-tests.py?rev=1029078&r1=1029077&r2=1029078&view=diff
==============================================================================
--- subversion/branches/performance/win-tests.py (original)
+++ subversion/branches/performance/win-tests.py Sat Oct 30 14:20:17 2010
@@ -226,7 +226,6 @@ if run_httpd:
     base_url = 'http://localhost:' + str(httpd_port)
 
 if base_url:
-  all_tests = client_tests
   repo_loc = 'remote repository ' + base_url + '.'
   if base_url[:4] == 'http':
     log = 'dav-tests.log'