Author: brane
Date: Sat Mar 10 15:27:24 2018
New Revision: 1826407

URL: http://svn.apache.org/viewvc?rev=1826407&view=rev
Log:
On the better-pristines branch: Sync with trunk up to r1826405.

Modified:
    subversion/branches/better-pristines/   (props changed)
    
subversion/branches/better-pristines/subversion/bindings/swig/python/tests/fs.py
    
subversion/branches/better-pristines/subversion/include/private/svn_wc_private.h
    subversion/branches/better-pristines/subversion/include/svn_client.h
    subversion/branches/better-pristines/subversion/include/svn_opt.h
    subversion/branches/better-pristines/subversion/include/svn_ra_svn.h
    subversion/branches/better-pristines/subversion/libsvn_client/client.h
    subversion/branches/better-pristines/subversion/libsvn_client/conflicts.c
    subversion/branches/better-pristines/subversion/libsvn_client/shelf.c
    subversion/branches/better-pristines/subversion/libsvn_delta/debug_editor.c
    subversion/branches/better-pristines/subversion/libsvn_fs_fs/id.c
    subversion/branches/better-pristines/subversion/libsvn_subr/lz4/lz4.c
    subversion/branches/better-pristines/subversion/libsvn_subr/opt.c
    subversion/branches/better-pristines/subversion/libsvn_subr/sysinfo.c
    subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.c
    subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.h
    subversion/branches/better-pristines/subversion/libsvn_wc/questions.c
    subversion/branches/better-pristines/subversion/libsvn_wc/tree_conflicts.c
    subversion/branches/better-pristines/subversion/libsvn_wc/update_editor.c
    subversion/branches/better-pristines/subversion/libsvn_wc/upgrade.c
    subversion/branches/better-pristines/subversion/libsvn_wc/wc_db.c
    
subversion/branches/better-pristines/subversion/libsvn_wc/wc_db_update_move.c
    
subversion/branches/better-pristines/subversion/mod_authz_svn/mod_authz_svn.c
    subversion/branches/better-pristines/subversion/po/sv.po
    subversion/branches/better-pristines/subversion/svn/cl.h
    subversion/branches/better-pristines/subversion/svn/help-cmd.c
    subversion/branches/better-pristines/subversion/svn/shelf-cmd.c
    subversion/branches/better-pristines/subversion/svn/svn.c
    subversion/branches/better-pristines/subversion/svnadmin/svnadmin.c
    subversion/branches/better-pristines/subversion/svnbench/cl.h
    subversion/branches/better-pristines/subversion/svnbench/help-cmd.c
    subversion/branches/better-pristines/subversion/svnbench/svnbench.c
    
subversion/branches/better-pristines/subversion/svndumpfilter/svndumpfilter.c
    subversion/branches/better-pristines/subversion/svnfsfs/svnfsfs.c
    subversion/branches/better-pristines/subversion/svnlook/svnlook.c
    subversion/branches/better-pristines/subversion/svnrdump/svnrdump.c
    subversion/branches/better-pristines/subversion/svnsync/svnsync.c
    
subversion/branches/better-pristines/subversion/tests/cmdline/getopt_tests_data/svn--help_stdout
    
subversion/branches/better-pristines/subversion/tests/cmdline/getopt_tests_data/svn_help_stdout
    
subversion/branches/better-pristines/subversion/tests/cmdline/update_tests.py
    
subversion/branches/better-pristines/subversion/tests/libsvn_client/conflicts-test.c
    subversion/branches/better-pristines/subversion/tests/libsvn_subr/utf-test.c
    
subversion/branches/better-pristines/subversion/tests/libsvn_wc/conflict-data-test.c
    
subversion/branches/better-pristines/subversion/tests/libsvn_wc/op-depth-test.c
    subversion/branches/better-pristines/tools/client-side/bash_completion
    
subversion/branches/better-pristines/tools/client-side/svn-mergeinfo-normalizer/help-cmd.c
    
subversion/branches/better-pristines/tools/client-side/svn-mergeinfo-normalizer/mergeinfo-normalizer.h
    
subversion/branches/better-pristines/tools/client-side/svn-mergeinfo-normalizer/svn-mergeinfo-normalizer.c
    
subversion/branches/better-pristines/tools/client-side/svnconflict/svnconflict.c
    subversion/branches/better-pristines/tools/dist/templates/download.ezt
    subversion/branches/better-pristines/tools/server-side/svnauthz.c

Propchange: subversion/branches/better-pristines/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sat Mar 10 15:27:24 2018
@@ -99,4 +99,4 @@
 /subversion/branches/verify-at-commit:1462039-1462408
 /subversion/branches/verify-keep-going:1439280-1546110
 /subversion/branches/wc-collate-path:1402685-1480384
-/subversion/trunk:1807118-1825302
+/subversion/trunk:1807118-1826405

Modified: 
subversion/branches/better-pristines/subversion/bindings/swig/python/tests/fs.py
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/bindings/swig/python/tests/fs.py?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- 
subversion/branches/better-pristines/subversion/bindings/swig/python/tests/fs.py
 (original)
+++ 
subversion/branches/better-pristines/subversion/bindings/swig/python/tests/fs.py
 Sat Mar 10 15:27:24 2018
@@ -19,8 +19,9 @@
 # under the License.
 #
 #
-import os, unittest, sys
+import os, unittest, sys, errno
 from tempfile import mkstemp
+from subprocess import Popen, PIPE
 try:
   # Python >=3.0
   from urllib.parse import urljoin
@@ -46,23 +47,13 @@ class SubversionFSTestCase(unittest.Test
     self.fs = repos.fs(self.repos)
     self.rev = fs.youngest_rev(self.fs)
     self.tmpfile = None
-
-  def tearDown(self):
-    self.fs = None
-    self.repos = None
-    self.temper.cleanup()
-
-    if self.tmpfile is not None:
-      os.remove(self.tmpfile)
-
-  def test_diff_repos_paths(self):
-    """Test diffing of a repository path."""
+    self.unistr = u'⊙_ʘ'
     tmpfd, self.tmpfile = mkstemp()
 
     tmpfp = os.fdopen(tmpfd, "wb")
 
     # Use a unicode file to ensure proper non-ascii handling.
-    tmpfp.write(u'⊙_ʘ'.encode('utf8'))
+    tmpfp.write(self.unistr.encode('utf8'))
 
     tmpfp.close()
 
@@ -81,27 +72,48 @@ class SubversionFSTestCase(unittest.Test
                                 urljoin(self.repos_uri +"/", 
"trunk/UniTest.txt"),
                                 True, True,
                                 clientctx)
-    self.assertEqual(commitinfo.revision, self.rev + 1)
+
+    self.commitedrev = commitinfo.revision
+
+  def tearDown(self):
+    self.fs = None
+    self.repos = None
+    self.temper.cleanup()
+
+    if self.tmpfile is not None:
+      os.remove(self.tmpfile)
+
+  def test_diff_repos_paths_internal(self):
+    """Test diffing of a repository path using the internal diff."""
 
     # Test standard internal diff
-    fdiff = fs.FileDiff(fs.revision_root(self.fs, commitinfo.revision), 
"/trunk/UniTest.txt",
+    fdiff = fs.FileDiff(fs.revision_root(self.fs, self.commitedrev), 
"/trunk/UniTest.txt",
                         None, None, diffoptions=None)
 
     diffp = fdiff.get_pipe()
     diffoutput = diffp.read().decode('utf8')
 
-    self.assertTrue(diffoutput.find(u'-⊙_ʘ') > 0)
+    self.assertTrue(diffoutput.find(u'-' + self.unistr) > 0)
+
+  def test_diff_repos_paths_external(self):
+    """Test diffing of a repository path using an external diff (if 
available)."""
+
+    # Test if this environment has the diff command, if not then skip the test
+    try:
+      diffout, differr = Popen(["diff"], stdin=PIPE, stderr=PIPE).communicate()
+
+    except OSError as err:
+      if err.errno == errno.ENOENT:
+        self.skipTest("'diff' command not present")
+      else:
+        raise err
 
-    # Test passing diffoptions to an external 'diff' executable.
-    # It is unusual to have the 'diff' tool on Windows, so do not
-    # try the test there.
-    if sys.platform != "win32":
-      fdiff = fs.FileDiff(fs.revision_root(self.fs, commitinfo.revision), 
"/trunk/UniTest.txt",
-                          None, None, diffoptions=['--normal'])
-      diffp = fdiff.get_pipe()
-      diffoutput = diffp.read().decode('utf8')
+    fdiff = fs.FileDiff(fs.revision_root(self.fs, self.commitedrev), 
"/trunk/UniTest.txt",
+                        None, None, diffoptions=[])
+    diffp = fdiff.get_pipe()
+    diffoutput = diffp.read().decode('utf8')
 
-      self.assertTrue(diffoutput.find(u'< ⊙_ʘ') > 0)
+    self.assertTrue(diffoutput.find(u'< ' + self.unistr) > 0)
 
 def suite():
     return unittest.defaultTestLoader.loadTestsFromTestCase(

Modified: 
subversion/branches/better-pristines/subversion/include/private/svn_wc_private.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/include/private/svn_wc_private.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- 
subversion/branches/better-pristines/subversion/include/private/svn_wc_private.h
 (original)
+++ 
subversion/branches/better-pristines/subversion/include/private/svn_wc_private.h
 Sat Mar 10 15:27:24 2018
@@ -2044,11 +2044,27 @@ svn_wc__acquire_write_lock_for_resolve(c
 
 /* The implemementation of svn_wc_diff6(), but reporting to a diff processor
  *
- * If ROOT_RELPATH is not NULL, set *ROOT_RELPATH to the target of the diff
- * within the diff namespace. ("" or a single path component).
+ * New mode: when ROOT_RELPATH is not NULL:
  *
- * If ROOT_IS_FILE is NOT NULL set it
- * the first processor call. (The anchor is LOCAL_ABSPATH or an ancestor of it)
+ *   If LOCAL_ABSPATH is the WC root, set *ROOT_RELPATH to "" and send
+ *   diff processor relpaths relative to LOCAL_ABSPATH; otherwise set
+ *   *ROOT_RELPATH to the last component of LOCAL_ABSPATH and send diff
+ *   processor relpaths relative to the parent of LOCAL_ABSPATH.
+ *   (*ROOT_RELPATH will be either "" or a single path component.)
+ *
+ * Backward compatibility mode for svn_wc_diff6(): when ROOT_RELPATH is NULL:
+ *
+ *   Send diff processor relpaths relative to LOCAL_ABSPATH if it is a
+ *   directory; otherwise, relative to the parent of LOCAL_ABSPATH.
+ *   This matches the "anchor and target" semantics of svn_wc_diff6().
+ *
+ * If ROOT_IS_DIR is not NULL:
+ *
+ *   Set *ROOT_IS_DIR to TRUE if the working version of LOCAL_ABSPATH is
+ *   a directory, else to FALSE.
+ *
+ * Assignments to *ROOT_RELPATH and *ROOT_IS_DIR are made before the first
+ * call to DIFF_PROCESSOR.
  */
 svn_error_t *
 svn_wc__diff7(const char **root_relpath,

Modified: subversion/branches/better-pristines/subversion/include/svn_client.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/include/svn_client.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/include/svn_client.h 
(original)
+++ subversion/branches/better-pristines/subversion/include/svn_client.h Sat 
Mar 10 15:27:24 2018
@@ -7002,7 +7002,7 @@ svn_client_shelf_set_current_version(svn
                                      int version,
                                      apr_pool_t *scratch_pool);
 
-/** Open an existing shelf version.
+/** Open an existing @a shelf_version, or error if it doesn't exist.
  *
  * There is no need to "close" it after use.
  *
@@ -7017,7 +7017,7 @@ svn_client_shelf_version_open(svn_client
                               apr_pool_t *result_pool,
                               apr_pool_t *scratch_pool);
 
-/** Apply version @a version of @a shelf to the WC.
+/** Apply @a shelf_version to the WC.
  *
  * @since New in 1.X.
  * @warning EXPERIMENTAL.
@@ -7028,7 +7028,7 @@ svn_client_shelf_apply(svn_client_shelf_
                        svn_boolean_t dry_run,
                        apr_pool_t *scratch_pool);
 
-/** Reverse-apply the current version of @a shelf to the WC.
+/** Reverse-apply @a shelf_version to the WC.
  *
  * @since New in 1.X.
  * @warning EXPERIMENTAL.
@@ -7050,7 +7050,7 @@ svn_client_shelf_get_patch_abspath(const
                                    svn_client_shelf_version_t *shelf_version,
                                    apr_pool_t *scratch_pool);
 
-/** Output version @a version of @a shelf as a patch to @a outstream.
+/** Output @a shelf_version as a patch to @a outstream.
  *
  * @since New in 1.X.
  * @warning EXPERIMENTAL.
@@ -7062,9 +7062,12 @@ svn_client_shelf_export_patch(svn_client
                               apr_pool_t *scratch_pool);
 
 /** Set @a *affected_paths to a hash with one entry for each path affected
- * by the @a shelf @a version. The hash key is the old path and value is
- * the new path, both relative to the WC root. The key and value are the
- * same except when a path is moved or copied.
+ * by the @a shelf_version.
+ *
+ * The hash key is the path of the affected file, relative to the WC root.
+ *
+ * (Future possibility: When moves and copies are supported, the hash key
+ * is the old path and value is the new path.)
  *
  * @since New in 1.10, changed in 1.X.
  * @warning EXPERIMENTAL.
@@ -7076,23 +7079,93 @@ svn_client_shelf_paths_changed(apr_hash_
                                apr_pool_t *result_pool,
                                apr_pool_t *scratch_pool);
 
-/** Set the log message in @a shelf, using the log message callbacks in
- * the client context, and set other revprops to @a revprop_table.
+/** Set @a shelf's revprop @a prop_name to @a prop_val.
+ *
+ * This can be used to set or change the shelf's log message
+ * (property name "svn:log" or #SVN_PROP_REVISION_LOG).
+ *
+ * If @a prop_val is NULL, delete the property (if present).
  *
  * @since New in 1.X.
  * @warning EXPERIMENTAL.
  */
 SVN_EXPERIMENTAL
 svn_error_t *
-svn_client_shelf_set_log_message(svn_client_shelf_t *shelf,
+svn_client_shelf_revprop_set(svn_client_shelf_t *shelf,
+                             const char *prop_name,
+                             const svn_string_t *prop_val,
+                             apr_pool_t *scratch_pool);
+
+/** Set @a shelf's revprops to @a revprop_table.
+ *
+ * This deletes all previous revprops.
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_set_all(svn_client_shelf_t *shelf,
                                  apr_hash_t *revprop_table,
-                                 svn_boolean_t dry_run,
+                                 apr_pool_t *scratch_pool);
+
+/** Get @a shelf's revprop @a prop_name into @a *prop_val.
+ *
+ * If the property is not present, set @a *prop_val to NULL.
+ *
+ * This can be used to get the shelf's log message
+ * (property name "svn:log" or #SVN_PROP_REVISION_LOG).
+ *
+ * The lifetime of the result is limited to that of @a shelf and/or
+ * of @a result_pool.
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_get(svn_string_t **prop_val,
+                             svn_client_shelf_t *shelf,
+                             const char *prop_name,
+                             apr_pool_t *result_pool);
+
+/** Get @a shelf's revprops into @a props.
+ *
+ * The lifetime of the result is limited to that of @a shelf and/or
+ * of @a result_pool.
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_list(apr_hash_t **props,
+                              svn_client_shelf_t *shelf,
+                              apr_pool_t *result_pool);
+
+/** Set the log message in @a shelf to @a log_message.
+ *
+ * If @a log_message is null, delete the log message.
+ *
+ * Similar to svn_client_shelf_revprop_set(... SVN_PROP_REVISION_LOG ...).
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_set_log_message(svn_client_shelf_t *shelf,
+                                 const char *log_message,
                                  apr_pool_t *scratch_pool);
 
 /** Get the log message in @a shelf into @a *log_message.
  *
  * Set @a *log_message to NULL if there is no log message.
  *
+ * Similar to svn_client_shelf_revprop_get(... SVN_PROP_REVISION_LOG ...).
+ *
+ * The result is allocated in @a result_pool.
+ *
  * @since New in 1.X.
  * @warning EXPERIMENTAL.
  */
@@ -7112,8 +7185,9 @@ typedef struct svn_client_shelf_info_t
   apr_time_t mtime;  /* mtime of the latest change */
 } svn_client_shelf_info_t;
 
-/** Set @a *shelved_patch_infos to a hash, keyed by shelf name, of pointers to
- * @c svn_client_shelf_info_t structures.
+/** Set @a *shelf_infos to a hash, keyed by shelf name, of pointers to
+ * @c svn_client_shelf_info_t structures, one for each shelf in the
+ * given WC.
  *
  * @a local_abspath is any path in the WC and is used to find the WC root.
  *

Modified: subversion/branches/better-pristines/subversion/include/svn_opt.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/include/svn_opt.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/include/svn_opt.h (original)
+++ subversion/branches/better-pristines/subversion/include/svn_opt.h Sat Mar 
10 15:27:24 2018
@@ -69,6 +69,10 @@ typedef svn_error_t *(svn_opt_subcommand
 /** The maximum number of options that can be accepted by a subcommand. */
 #define SVN_OPT_MAX_OPTIONS 50
 
+/** The maximum number of paragraphs of help text a subcommand can have.
+ * @since New in 1.11. */
+#define SVN_OPT_MAX_PARAGRAPHS 100
+
 /** Options that have no short option char should use an identifying
  * integer equal to or greater than this.
  */
@@ -77,6 +81,37 @@ typedef svn_error_t *(svn_opt_subcommand
 
 /** One element of a subcommand dispatch table.
  *
+ * @since New in 1.11.
+ */
+typedef struct svn_opt_subcommand_desc3_t
+{
+  /** The full name of this command. */
+  const char *name;
+
+  /** The function this command invokes. */
+  svn_opt_subcommand_t *cmd_func;
+
+  /** A list of alias names for this command (e.g., 'up' for 'update'). */
+  const char *aliases[SVN_OPT_MAX_ALIASES];
+
+  /** A multi-paragraph string describing this command. */
+  const char *help[SVN_OPT_MAX_PARAGRAPHS];
+
+  /** A list of options accepted by this command.  Each value in the
+   * array is a unique enum (the 2nd field in apr_getopt_option_t)
+   */
+  int valid_options[SVN_OPT_MAX_OPTIONS];
+
+  /** A list of option help descriptions, keyed by the option unique enum
+   * (the 2nd field in apr_getopt_option_t), which override the generic
+   * descriptions given in an apr_getopt_option_t on a per-subcommand basis.
+   */
+  struct { int optch; const char *desc; } desc_overrides[SVN_OPT_MAX_OPTIONS];
+} svn_opt_subcommand_desc3_t;
+
+
+/** One element of a subcommand dispatch table.
+ *
  * @since New in 1.4.
  */
 typedef struct svn_opt_subcommand_desc2_t
@@ -139,6 +174,17 @@ typedef struct svn_opt_subcommand_desc_t
  * Return the entry in @a table whose name matches @a cmd_name, or @c NULL if
  * none.  @a cmd_name may be an alias.
  *
+ * @since New in 1.11.
+ */
+const svn_opt_subcommand_desc3_t *
+svn_opt_get_canonical_subcommand3(const svn_opt_subcommand_desc3_t *table,
+                                  const char *cmd_name);
+
+
+/**
+ * Same as svn_opt_get_canonical_subcommand3(), but with a different
+ * version of the subcommand description table.
+ *
  * @since New in 1.4.
  */
 const svn_opt_subcommand_desc2_t *
@@ -170,6 +216,18 @@ svn_opt_get_canonical_subcommand(const s
  *
  * The returned value may be statically allocated, or allocated in @a pool.
  *
+ * @since New in 1.11.
+ */
+const apr_getopt_option_t *
+svn_opt_get_option_from_code3(int code,
+                              const apr_getopt_option_t *option_table,
+                              const svn_opt_subcommand_desc3_t *command,
+                              apr_pool_t *pool);
+
+/**
+ * Same as svn_opt_get_option_from_code3(), but with a different
+ * version of the subcommand description table.
+ *
  * @since New in 1.4.
  */
 const apr_getopt_option_t *
@@ -198,6 +256,17 @@ svn_opt_get_option_from_code(int code,
  * non-NULL, it is a zero-terminated array, and all subcommands take
  * the options listed in it.
  *
+ * @since New in 1.11.
+ */
+svn_boolean_t
+svn_opt_subcommand_takes_option4(const svn_opt_subcommand_desc3_t *command,
+                                 int option_code,
+                                 const int *global_options);
+
+/**
+ * Same as svn_opt_subcommand_takes_option4(), but with a different
+ * version of the subcommand description table.
+ *
  * @since New in 1.5.
  */
 svn_boolean_t
@@ -244,6 +313,20 @@ svn_opt_subcommand_takes_option(const sv
  *
  * Use @a pool for temporary allocation.
  *
+ * @since New in 1.11.
+ */
+void
+svn_opt_print_generic_help3(const char *header,
+                            const svn_opt_subcommand_desc3_t *cmd_table,
+                            const apr_getopt_option_t *opt_table,
+                            const char *footer,
+                            apr_pool_t *pool,
+                            FILE *stream);
+
+/**
+ * Same as svn_opt_print_generic_help3(), but with a different
+ * version of the subcommand description table.
+ *
  * @since New in 1.4.
  */
 void
@@ -297,6 +380,19 @@ svn_opt_format_option(const char **strin
  * use that second name as an alias for the first name.  This additional
  * behaviour is new in 1.7.
  *
+ * @since New in 1.11.
+ */
+void
+svn_opt_subcommand_help4(const char *subcommand,
+                         const svn_opt_subcommand_desc3_t *table,
+                         const apr_getopt_option_t *options_table,
+                         const int *global_options,
+                         apr_pool_t *pool);
+
+/**
+ * Same as svn_opt_subcommand_help4(), but with a different
+ * version of the subcommand description table.
+ *
  * @since New in 1.5.
  */
 void
@@ -700,9 +796,28 @@ svn_opt_parse_path(svn_opt_revision_t *r
  * --version flag *and* subcommand arguments on a help command line.
  * The logic for handling such a situation should be in one place.
  *
- * @since New in 1.8.
+ * @since New in 1.11.
  */
+svn_error_t *
+svn_opt_print_help5(apr_getopt_t *os,
+                    const char *pgm_name,
+                    svn_boolean_t print_version,
+                    svn_boolean_t quiet,
+                    svn_boolean_t verbose,
+                    const char *version_footer,
+                    const char *header,
+                    const svn_opt_subcommand_desc3_t *cmd_table,
+                    const apr_getopt_option_t *option_table,
+                    const int *global_options,
+                    const char *footer,
+                    apr_pool_t *pool);
 
+/**
+ * Same as svn_opt_print_help5(), but with a different
+ * version of the subcommand description table.
+ *
+ * @since New in 1.8.
+ */
 svn_error_t *
 svn_opt_print_help4(apr_getopt_t *os,
                     const char *pgm_name,

Modified: subversion/branches/better-pristines/subversion/include/svn_ra_svn.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/include/svn_ra_svn.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/include/svn_ra_svn.h 
(original)
+++ subversion/branches/better-pristines/subversion/include/svn_ra_svn.h Sat 
Mar 10 15:27:24 2018
@@ -179,7 +179,7 @@ typedef svn_error_t *(*svn_ra_svn_edit_c
  *
  * Either @a sock or @a in_stream/@a out_stream must be set, not both.
  * @a compression_level specifies the desired network data compression
- * level (zlib) from 0 (no compression) to 9 (best but slowest).
+ * level (zlib/lz4) from 0 (no compression) to 9 (best but slowest).
  *
  * If @a zero_copy_limit is not 0, cached file contents smaller than the
  * given limit may be sent directly to the network socket.  Otherwise,

Modified: subversion/branches/better-pristines/subversion/libsvn_client/client.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_client/client.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_client/client.h 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_client/client.h Sat 
Mar 10 15:27:24 2018
@@ -1112,14 +1112,34 @@ svn_client__resolve_conflicts(svn_boolea
                               svn_client_ctx_t *ctx,
                               apr_pool_t *scratch_pool);
 
-/* Produce a diff with depth DEPTH between two files or two directories at
- * LEFT_ABSPATH1 and RIGHT_ABSPATH, using the provided diff callbacks to
- * show changes in files. The files and directories involved may be part of
- * a working copy or they may be unversioned. For versioned files, show
- * property changes, too.
- *
- * If ANCHOR_ABSPATH is not null, set it to the anchor of the diff before
- * the first processor call. (The anchor is LEFT_ABSPATH or an ancestor of it)
+/* Produce a diff with depth DEPTH between the file or directory at
+ * LEFT_ABSPATH and the file or directory at RIGHT_ABSPATH, reporting
+ * differences to DIFF_PROCESSOR.
+ *
+ * The files and directories involved may be part of a working copy or
+ * they may be unversioned. For versioned files, show property changes,
+ * too.
+ *
+ * No copy or move information is reported to the diff processor.
+ *
+ * If both LEFT_ABSPATH and RIGHT_ABSPATH are directories on disk:
+ *   set *ROOT_RELPATH to "" and
+ *   set *ROOT_IS_DIR to TRUE and
+ *   send diff processor relpaths relative to LEFT_ABSPATH
+ *   (which is the same as relative to RIGHT_ABSPATH);
+ * else:
+ *   set *ROOT_RELPATH to the basename of LEFT_ABSPATH and
+ *   set *ROOT_IS_DIR to FALSE and
+ *   send diff processor relpaths relative to the parent of LEFT_ABSPATH
+ *   (so they all start with a basename(LEFT_ABSPATH) component).
+ *
+ * As any children reached by recursion are matched by name, a diff
+ * processor relpath applies equally to both sides of the diff, except
+ * for its first component in the latter case above.
+ *
+ * Assignments to *ROOT_RELPATH and *ROOT_IS_DIR are made before the first
+ * call to DIFF_PROCESSOR. Each of ROOT_RELPATH and ROOT_IS_DIR may be NULL
+ * if not wanted.
  */
 svn_error_t *
 svn_client__arbitrary_nodes_diff(const char **root_relpath,
@@ -1250,39 +1270,6 @@ svn_client__merge_locked(svn_client__con
                          apr_pool_t *result_pool,
                          apr_pool_t *scratch_pool);
 
-/** Set @a shelf's revprop @a prop_name to @a prop_val.
- *
- * If @a prop_val is NULL, delete the property (if present).
- */
-svn_error_t *
-svn_client__shelf_revprop_set(svn_client_shelf_t *shelf,
-                               const char *prop_name,
-                               const svn_string_t *prop_val,
-                               apr_pool_t *scratch_pool);
-
-/** Get @a shelf's revprop @a prop_name into @a *prop_val.
- *
- * If the property is not present, set @a *prop_val to NULL.
- *
- * The lifetime of the result is limited to that of @a shelf and/or
- * of @a result_pool.
- */
-svn_error_t *
-svn_client__shelf_revprop_get(svn_string_t **prop_val,
-                               svn_client_shelf_t *shelf,
-                               const char *prop_name,
-                               apr_pool_t *result_pool);
-
-/** Get @a shelf's revprops into @a props.
- *
- * The lifetime of the result is limited to that of @a shelf and/or
- * of @a result_pool.
- */
-svn_error_t *
-svn_client__shelf_revprop_list(apr_hash_t **props,
-                               svn_client_shelf_t *shelf,
-                               apr_pool_t *result_pool);
-
 #ifdef __cplusplus
 }
 #endif /* __cplusplus */

Modified: 
subversion/branches/better-pristines/subversion/libsvn_client/conflicts.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_client/conflicts.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_client/conflicts.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_client/conflicts.c 
Sat Mar 10 15:27:24 2018
@@ -9674,11 +9674,13 @@ configure_option_incoming_delete_ignore(
       incoming_details = conflict->tree_conflict_incoming_details;
       is_incoming_move = (incoming_details != NULL &&
                           incoming_details->moves != NULL);
-      if (local_change == svn_wc_conflict_reason_edited && is_incoming_move)
+      if (local_change == svn_wc_conflict_reason_moved_away ||
+          local_change == svn_wc_conflict_reason_edited)
         {
           /* An option which ignores the incoming deletion makes no sense
-           * if we know it is actually a move. */
-          return SVN_NO_ERROR;
+           * if we know there was a local move and/or an incoming move. */
+          if (is_incoming_move)
+            return SVN_NO_ERROR;
         }
       else if (local_change == svn_wc_conflict_reason_deleted)
         {
@@ -9739,14 +9741,17 @@ configure_option_incoming_delete_accept(
   if (incoming_change == svn_wc_conflict_action_delete)
     {
       struct conflict_tree_incoming_delete_details *incoming_details;
+      svn_boolean_t is_incoming_move;
 
       incoming_details = conflict->tree_conflict_incoming_details;
-
-      if (local_change == svn_wc_conflict_reason_edited &&
-          incoming_details != NULL && incoming_details->moves != NULL)
+      is_incoming_move = (incoming_details != NULL &&
+                          incoming_details->moves != NULL);
+      if (is_incoming_move &&
+          (local_change == svn_wc_conflict_reason_edited ||
+          local_change == svn_wc_conflict_reason_moved_away))
         {
           /* An option which accepts the incoming deletion makes no sense
-           * if we know it is actually a move. */
+           * if we know there was a local move and/or an incoming move. */
           return SVN_NO_ERROR;
         }
       else
@@ -9894,6 +9899,7 @@ configure_option_incoming_dir_merge(svn_
 {
   svn_node_kind_t victim_node_kind;
   svn_wc_conflict_action_t incoming_change;
+  svn_wc_conflict_reason_t local_change;
   const char *incoming_old_repos_relpath;
   svn_revnum_t incoming_old_pegrev;
   svn_node_kind_t incoming_old_kind;
@@ -9902,6 +9908,7 @@ configure_option_incoming_dir_merge(svn_
   svn_node_kind_t incoming_new_kind;
 
   incoming_change = svn_client_conflict_get_incoming_change(conflict);
+  local_change = svn_client_conflict_get_local_change(conflict);
   victim_node_kind = svn_client_conflict_tree_get_victim_node_kind(conflict);
   SVN_ERR(svn_client_conflict_get_incoming_old_repos_location(
             &incoming_old_repos_relpath, &incoming_old_pegrev,
@@ -9915,7 +9922,8 @@ configure_option_incoming_dir_merge(svn_
   if (victim_node_kind == svn_node_dir &&
       incoming_old_kind == svn_node_dir &&
       incoming_new_kind == svn_node_none &&
-      incoming_change == svn_wc_conflict_action_delete)
+      incoming_change == svn_wc_conflict_action_delete &&
+      local_change == svn_wc_conflict_reason_edited)
     {
       struct conflict_tree_incoming_delete_details *details;
       const char *description;

Modified: subversion/branches/better-pristines/subversion/libsvn_client/shelf.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_client/shelf.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_client/shelf.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_client/shelf.c Sat 
Mar 10 15:27:24 2018
@@ -237,10 +237,10 @@ shelf_write_revprops(svn_client_shelf_t
 }
 
 svn_error_t *
-svn_client__shelf_revprop_set(svn_client_shelf_t *shelf,
-                              const char *prop_name,
-                              const svn_string_t *prop_val,
-                              apr_pool_t *scratch_pool)
+svn_client_shelf_revprop_set(svn_client_shelf_t *shelf,
+                             const char *prop_name,
+                             const svn_string_t *prop_val,
+                             apr_pool_t *scratch_pool)
 {
   svn_hash_sets(shelf->revprops, apr_pstrdup(shelf->pool, prop_name),
                 svn_string_dup(prop_val, shelf->pool));
@@ -249,19 +249,32 @@ svn_client__shelf_revprop_set(svn_client
 }
 
 svn_error_t *
-svn_client__shelf_revprop_get(svn_string_t **prop_val,
-                              svn_client_shelf_t *shelf,
-                              const char *prop_name,
-                              apr_pool_t *result_pool)
+svn_client_shelf_revprop_set_all(svn_client_shelf_t *shelf,
+                                 apr_hash_t *revprop_table,
+                                 apr_pool_t *scratch_pool)
+{
+  if (revprop_table)
+    shelf->revprops = svn_prop_hash_dup(revprop_table, shelf->pool);
+  else
+    shelf->revprops = apr_hash_make(shelf->pool);
+
+  return SVN_NO_ERROR;
+}
+
+svn_error_t *
+svn_client_shelf_revprop_get(svn_string_t **prop_val,
+                             svn_client_shelf_t *shelf,
+                             const char *prop_name,
+                             apr_pool_t *result_pool)
 {
   *prop_val = svn_hash_gets(shelf->revprops, prop_name);
   return SVN_NO_ERROR;
 }
 
 svn_error_t *
-svn_client__shelf_revprop_list(apr_hash_t **props,
-                               svn_client_shelf_t *shelf,
-                               apr_pool_t *result_pool)
+svn_client_shelf_revprop_list(apr_hash_t **props,
+                              svn_client_shelf_t *shelf,
+                              apr_pool_t *result_pool)
 {
   *props = shelf->revprops;
   return SVN_NO_ERROR;
@@ -679,7 +692,7 @@ svn_client_shelf_get_log_message(char **
                                  svn_client_shelf_t *shelf,
                                  apr_pool_t *result_pool)
 {
-  svn_string_t *propval = svn_hash_gets(shelf->revprops, "svn:log");
+  svn_string_t *propval = svn_hash_gets(shelf->revprops, 
SVN_PROP_REVISION_LOG);
 
   if (propval)
     *log_message = apr_pstrdup(result_pool, propval->data);
@@ -690,39 +703,14 @@ svn_client_shelf_get_log_message(char **
 
 svn_error_t *
 svn_client_shelf_set_log_message(svn_client_shelf_t *shelf,
-                                 apr_hash_t *revprop_table,
-                                 svn_boolean_t dry_run,
+                                 const char *message,
                                  apr_pool_t *scratch_pool)
 {
-  svn_client_ctx_t *ctx = shelf->ctx;
-  const char *message = "";
-
-  /* Fetch the log message and any other revprops */
-  if (SVN_CLIENT__HAS_LOG_MSG_FUNC(ctx))
-    {
-      const char *tmp_file;
-      apr_array_header_t *commit_items
-        = apr_array_make(scratch_pool, 1, sizeof(void *));
-
-      SVN_ERR(svn_client__get_log_msg(&message, &tmp_file, commit_items,
-                                      ctx, scratch_pool));
-      if (! message)
-        return SVN_NO_ERROR;
-    }
-
-  if (revprop_table)
-    shelf->revprops = svn_prop_hash_dup(revprop_table, shelf->pool);
-  else
-    shelf->revprops = apr_hash_make(shelf->pool);
-
-  if (message && !dry_run)
-    {
-      svn_string_t *propval = svn_string_create(message, shelf->pool);
-
-      SVN_ERR(svn_client__shelf_revprop_set(shelf, "svn:log", propval,
-                                            scratch_pool));
-    }
+  svn_string_t *propval
+    = message ? svn_string_create(message, shelf->pool) : NULL;
 
+  SVN_ERR(svn_client_shelf_revprop_set(shelf, SVN_PROP_REVISION_LOG, propval,
+                                       scratch_pool));
   return SVN_NO_ERROR;
 }
 

Modified: 
subversion/branches/better-pristines/subversion/libsvn_delta/debug_editor.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_delta/debug_editor.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_delta/debug_editor.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_delta/debug_editor.c 
Sat Mar 10 15:27:24 2018
@@ -458,7 +458,7 @@ svn_delta__get_debug_editor(const svn_de
                             const char *prefix,
                             apr_pool_t *pool)
 {
-  svn_delta_editor_t *tree_editor = apr_palloc(pool, sizeof(*tree_editor));
+  svn_delta_editor_t *tree_editor = svn_delta_default_editor(pool);
   struct edit_baton *eb = apr_palloc(pool, sizeof(*eb));
   apr_file_t *errfp;
   svn_stream_t *out;

Modified: subversion/branches/better-pristines/subversion/libsvn_fs_fs/id.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_fs_fs/id.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_fs_fs/id.c (original)
+++ subversion/branches/better-pristines/subversion/libsvn_fs_fs/id.c Sat Mar 
10 15:27:24 2018
@@ -591,7 +591,8 @@ svn_fs_fs__id_parse(const svn_fs_id_t **
   svn_fs_id_t *id = id_parse(data, pool);
   if (id == NULL)
     return svn_error_createf(SVN_ERR_FS_MALFORMED_NODEREV_ID, NULL,
-                             "Malformed node revision ID string");
+                             "Malformed node revision ID string '%s'",
+                             data);
 
   *id_p = id;
 

Modified: subversion/branches/better-pristines/subversion/libsvn_subr/lz4/lz4.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_subr/lz4/lz4.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_subr/lz4/lz4.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_subr/lz4/lz4.c Sat 
Mar 10 15:27:24 2018
@@ -1471,4 +1471,11 @@ int LZ4_decompress_fast_withPrefix64k(co
 }
 
 #endif   /* LZ4_COMMONDEFS_ONLY */
+#else /* !SVN_INTERNAL_LZ4 */
+
+/* Silence OSX ranlib warnings about object files with no symbols. */
+#include <apr.h>
+extern const apr_uint32_t svn__fake__lz4internal;
+const apr_uint32_t svn__fake__lz4internal = 0xdeadbeef;
+
 #endif /* SVN_INTERNAL_LZ4 */

Modified: subversion/branches/better-pristines/subversion/libsvn_subr/opt.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_subr/opt.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_subr/opt.c (original)
+++ subversion/branches/better-pristines/subversion/libsvn_subr/opt.c Sat Mar 
10 15:27:24 2018
@@ -55,6 +55,30 @@
 
 /*** Code. ***/
 
+const svn_opt_subcommand_desc3_t *
+svn_opt_get_canonical_subcommand3(const svn_opt_subcommand_desc3_t *table,
+                                  const char *cmd_name)
+{
+  int i = 0;
+
+  if (cmd_name == NULL)
+    return NULL;
+
+  while (table[i].name) {
+    int j;
+    if (strcmp(cmd_name, table[i].name) == 0)
+      return table + i;
+    for (j = 0; (j < SVN_OPT_MAX_ALIASES) && table[i].aliases[j]; j++)
+      if (strcmp(cmd_name, table[i].aliases[j]) == 0)
+        return table + i;
+
+    i++;
+  }
+
+  /* If we get here, there was no matching subcommand name or alias. */
+  return NULL;
+}
+
 const svn_opt_subcommand_desc2_t *
 svn_opt_get_canonical_subcommand2(const svn_opt_subcommand_desc2_t *table,
                                   const char *cmd_name)
@@ -80,6 +104,38 @@ svn_opt_get_canonical_subcommand2(const
 }
 
 const apr_getopt_option_t *
+svn_opt_get_option_from_code3(int code,
+                              const apr_getopt_option_t *option_table,
+                              const svn_opt_subcommand_desc3_t *command,
+                              apr_pool_t *pool)
+{
+  apr_size_t i;
+
+  for (i = 0; option_table[i].optch; i++)
+    if (option_table[i].optch == code)
+      {
+        if (command)
+          {
+            int j;
+
+            for (j = 0; ((j < SVN_OPT_MAX_OPTIONS) &&
+                         command->desc_overrides[j].optch); j++)
+              if (command->desc_overrides[j].optch == code)
+                {
+                  apr_getopt_option_t *tmpopt =
+                      apr_palloc(pool, sizeof(*tmpopt));
+                  *tmpopt = option_table[i];
+                  tmpopt->description = command->desc_overrides[j].desc;
+                  return tmpopt;
+                }
+          }
+        return &(option_table[i]);
+      }
+
+  return NULL;
+}
+
+const apr_getopt_option_t *
 svn_opt_get_option_from_code2(int code,
                               const apr_getopt_option_t *option_table,
                               const svn_opt_subcommand_desc2_t *command,
@@ -126,6 +182,34 @@ svn_opt_get_option_from_code(int code,
 }
 
 
+/* Like svn_opt_get_option_from_code3(), but also, if CODE appears a second
+ * time in OPTION_TABLE with a different name, then set *LONG_ALIAS to that
+ * second name, else set it to NULL. */
+static const apr_getopt_option_t *
+get_option_from_code3(const char **long_alias,
+                      int code,
+                      const apr_getopt_option_t *option_table,
+                      const svn_opt_subcommand_desc3_t *command,
+                      apr_pool_t *pool)
+{
+  const apr_getopt_option_t *i;
+  const apr_getopt_option_t *opt
+    = svn_opt_get_option_from_code3(code, option_table, command, pool);
+
+  /* Find a long alias in the table, if there is one. */
+  *long_alias = NULL;
+  for (i = option_table; i->optch; i++)
+    {
+      if (i->optch == code && i->name != opt->name)
+        {
+          *long_alias = i->name;
+          break;
+        }
+    }
+
+  return opt;
+}
+
 /* Like svn_opt_get_option_from_code2(), but also, if CODE appears a second
  * time in OPTION_TABLE with a different name, then set *LONG_ALIAS to that
  * second name, else set it to NULL. */
@@ -205,6 +289,25 @@ svn_opt_format_option(const char **strin
 
 
 svn_boolean_t
+svn_opt_subcommand_takes_option4(const svn_opt_subcommand_desc3_t *command,
+                                 int option_code,
+                                 const int *global_options)
+{
+  apr_size_t i;
+
+  for (i = 0; i < SVN_OPT_MAX_OPTIONS; i++)
+    if (command->valid_options[i] == option_code)
+      return TRUE;
+
+  if (global_options)
+    for (i = 0; global_options[i]; i++)
+      if (global_options[i] == option_code)
+        return TRUE;
+
+  return FALSE;
+}
+
+svn_boolean_t
 svn_opt_subcommand_takes_option3(const svn_opt_subcommand_desc2_t *command,
                                  int option_code,
                                  const int *global_options)
@@ -251,6 +354,114 @@ svn_opt_subcommand_takes_option(const sv
    STREAM.  If HELP is set, print CMD's help string too, in which case
    obtain option usage from OPTIONS_TABLE. */
 static svn_error_t *
+print_command_info3(const svn_opt_subcommand_desc3_t *cmd,
+                    const apr_getopt_option_t *options_table,
+                    const int *global_options,
+                    svn_boolean_t help,
+                    apr_pool_t *pool,
+                    FILE *stream)
+{
+  svn_boolean_t first_time;
+  apr_size_t i;
+
+  /* Print the canonical command name. */
+  SVN_ERR(svn_cmdline_fputs(cmd->name, stream, pool));
+
+  /* Print the list of aliases. */
+  first_time = TRUE;
+  for (i = 0; i < SVN_OPT_MAX_ALIASES; i++)
+    {
+      if (cmd->aliases[i] == NULL)
+        break;
+
+      if (first_time) {
+        SVN_ERR(svn_cmdline_fputs(" (", stream, pool));
+        first_time = FALSE;
+      }
+      else
+        SVN_ERR(svn_cmdline_fputs(", ", stream, pool));
+
+      SVN_ERR(svn_cmdline_fputs(cmd->aliases[i], stream, pool));
+    }
+
+  if (! first_time)
+    SVN_ERR(svn_cmdline_fputs(")", stream, pool));
+
+  if (help)
+    {
+      const apr_getopt_option_t *option;
+      const char *long_alias;
+      svn_boolean_t have_options = FALSE;
+
+      SVN_ERR(svn_cmdline_fprintf(stream, pool, ": "));
+
+      for (i = 0; i < SVN_OPT_MAX_PARAGRAPHS && cmd->help[i]; i++)
+        {
+          SVN_ERR(svn_cmdline_fprintf(stream, pool, "%s", _(cmd->help[i])));
+        }
+
+      /* Loop over all valid option codes attached to the subcommand */
+      for (i = 0; i < SVN_OPT_MAX_OPTIONS; i++)
+        {
+          if (cmd->valid_options[i])
+            {
+              if (!have_options)
+                {
+                  SVN_ERR(svn_cmdline_fputs(_("\nValid options:\n"),
+                                            stream, pool));
+                  have_options = TRUE;
+                }
+
+              /* convert each option code into an option */
+              option = get_option_from_code3(&long_alias, 
cmd->valid_options[i],
+                                             options_table, cmd, pool);
+
+              /* print the option's docstring */
+              if (option && option->description)
+                {
+                  const char *optstr;
+                  format_option(&optstr, option, long_alias, TRUE, pool);
+                  SVN_ERR(svn_cmdline_fprintf(stream, pool, "  %s\n",
+                                              optstr));
+                }
+            }
+        }
+      /* And global options too */
+      if (global_options && *global_options)
+        {
+          SVN_ERR(svn_cmdline_fputs(_("\nGlobal options:\n"),
+                                    stream, pool));
+          have_options = TRUE;
+
+          for (i = 0; global_options[i]; i++)
+            {
+
+              /* convert each option code into an option */
+              option = get_option_from_code3(&long_alias, global_options[i],
+                                             options_table, cmd, pool);
+
+              /* print the option's docstring */
+              if (option && option->description)
+                {
+                  const char *optstr;
+                  format_option(&optstr, option, long_alias, TRUE, pool);
+                  SVN_ERR(svn_cmdline_fprintf(stream, pool, "  %s\n",
+                                              optstr));
+                }
+            }
+        }
+
+      if (have_options)
+        SVN_ERR(svn_cmdline_fprintf(stream, pool, "\n"));
+    }
+
+  return SVN_NO_ERROR;
+}
+
+/* Print the canonical command name for CMD, and all its aliases, to
+   STREAM.  If HELP is set, print CMD's help string too, in which case
+   obtain option usage from OPTIONS_TABLE. */
+static svn_error_t *
 print_command_info2(const svn_opt_subcommand_desc2_t *cmd,
                     const apr_getopt_option_t *options_table,
                     const int *global_options,
@@ -350,6 +561,38 @@ print_command_info2(const svn_opt_subcom
   return SVN_NO_ERROR;
 }
 
+/* The body for svn_opt_print_generic_help3() function with standard error
+ * handling semantic. Handling of errors implemented at caller side. */
+static svn_error_t *
+print_generic_help_body3(const char *header,
+                         const svn_opt_subcommand_desc3_t *cmd_table,
+                         const apr_getopt_option_t *opt_table,
+                         const char *footer,
+                         apr_pool_t *pool, FILE *stream)
+{
+  int i = 0;
+
+  if (header)
+    SVN_ERR(svn_cmdline_fputs(header, stream, pool));
+
+  while (cmd_table[i].name)
+    {
+      SVN_ERR(svn_cmdline_fputs("   ", stream, pool));
+      SVN_ERR(print_command_info3(cmd_table + i, opt_table,
+                                  NULL, FALSE,
+                                  pool, stream));
+      SVN_ERR(svn_cmdline_fputs("\n", stream, pool));
+      i++;
+    }
+
+  SVN_ERR(svn_cmdline_fputs("\n", stream, pool));
+
+  if (footer)
+    SVN_ERR(svn_cmdline_fputs(footer, stream, pool));
+
+  return SVN_NO_ERROR;
+}
+
 /* The body for svn_opt_print_generic_help2() function with standard error
  * handling semantic. Handling of errors implemented at caller side. */
 static svn_error_t *
@@ -383,6 +626,30 @@ print_generic_help_body(const char *head
 }
 
 void
+svn_opt_print_generic_help3(const char *header,
+                            const svn_opt_subcommand_desc3_t *cmd_table,
+                            const apr_getopt_option_t *opt_table,
+                            const char *footer,
+                            apr_pool_t *pool, FILE *stream)
+{
+  svn_error_t *err;
+
+  err = print_generic_help_body3(header, cmd_table, opt_table, footer, pool,
+                                 stream);
+
+  /* Issue #3014:
+   * Don't print anything on broken pipes. The pipe was likely
+   * closed by the process at the other end. We expect that
+   * process to perform error reporting as necessary.
+   *
+   * ### This assumes that there is only one error in a chain for
+   * ### SVN_ERR_IO_PIPE_WRITE_ERROR. See svn_cmdline_fputs(). */
+  if (err && err->apr_err != SVN_ERR_IO_PIPE_WRITE_ERROR)
+    svn_handle_error2(err, stderr, FALSE, "svn: ");
+  svn_error_clear(err);
+}
+
+void
 svn_opt_print_generic_help2(const char *header,
                             const svn_opt_subcommand_desc2_t *cmd_table,
                             const apr_getopt_option_t *opt_table,
@@ -408,6 +675,32 @@ svn_opt_print_generic_help2(const char *
 
 
 void
+svn_opt_subcommand_help4(const char *subcommand,
+                         const svn_opt_subcommand_desc3_t *table,
+                         const apr_getopt_option_t *options_table,
+                         const int *global_options,
+                         apr_pool_t *pool)
+{
+  const svn_opt_subcommand_desc3_t *cmd =
+    svn_opt_get_canonical_subcommand3(table, subcommand);
+  svn_error_t *err;
+
+  if (cmd)
+    err = print_command_info3(cmd, options_table, global_options,
+                              TRUE, pool, stdout);
+  else
+    err = svn_cmdline_fprintf(stderr, pool,
+                              _("\"%s\": unknown command.\n\n"), subcommand);
+
+  if (err) {
+    /* Issue #3014: Don't print anything on broken pipes. */
+    if (err->apr_err != SVN_ERR_IO_PIPE_WRITE_ERROR)
+      svn_handle_error2(err, stderr, FALSE, "svn: ");
+    svn_error_clear(err);
+  }
+}
+
+void
 svn_opt_subcommand_help3(const char *subcommand,
                          const svn_opt_subcommand_desc2_t *table,
                          const apr_getopt_option_t *options_table,
@@ -1192,6 +1485,56 @@ svn_opt__print_version_info(const char *
 
   return SVN_NO_ERROR;
 }
+
+svn_error_t *
+svn_opt_print_help5(apr_getopt_t *os,
+                    const char *pgm_name,
+                    svn_boolean_t print_version,
+                    svn_boolean_t quiet,
+                    svn_boolean_t verbose,
+                    const char *version_footer,
+                    const char *header,
+                    const svn_opt_subcommand_desc3_t *cmd_table,
+                    const apr_getopt_option_t *option_table,
+                    const int *global_options,
+                    const char *footer,
+                    apr_pool_t *pool)
+{
+  apr_array_header_t *targets = NULL;
+
+  if (os)
+    SVN_ERR(svn_opt_parse_all_args(&targets, os, pool));
+
+  if (os && targets->nelts)  /* help on subcommand(s) requested */
+    {
+      int i;
+
+      for (i = 0; i < targets->nelts; i++)
+        {
+          svn_opt_subcommand_help4(APR_ARRAY_IDX(targets, i, const char *),
+                                   cmd_table, option_table,
+                                   global_options, pool);
+        }
+    }
+  else if (print_version)   /* just --version */
+    {
+      SVN_ERR(svn_opt__print_version_info(pgm_name, version_footer,
+                                          svn_version_extended(verbose, pool),
+                                          quiet, verbose, pool));
+    }
+  else if (os && !targets->nelts)            /* `-h', `--help', or `help' */
+    svn_opt_print_generic_help3(header,
+                                cmd_table,
+                                option_table,
+                                footer,
+                                pool,
+                                stdout);
+  else                                       /* unknown option or cmd */
+    SVN_ERR(svn_cmdline_fprintf(stderr, pool,
+                                _("Type '%s help' for usage.\n"), pgm_name));
+
+  return SVN_NO_ERROR;
+}
 
 svn_error_t *
 svn_opt_print_help4(apr_getopt_t *os,

Modified: subversion/branches/better-pristines/subversion/libsvn_subr/sysinfo.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_subr/sysinfo.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_subr/sysinfo.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_subr/sysinfo.c Sat 
Mar 10 15:27:24 2018
@@ -1155,6 +1155,7 @@ release_name_from_version(const char *os
     case 10: return "Yosemite";
     case 11: return "El Capitan";
     case 12: return "Sierra";
+    case 13: return "High Sierra";
     }
 
   return NULL;

Modified: subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.c Sat 
Mar 10 15:27:24 2018
@@ -539,6 +539,7 @@ svn_wc__conflict_skel_add_tree_conflict(
                                         svn_wc_conflict_reason_t reason,
                                         svn_wc_conflict_action_t action,
                                         const char *move_src_op_root_abspath,
+                                        const char *move_dst_op_root_abspath,
                                         apr_pool_t *result_pool,
                                         apr_pool_t *scratch_pool)
 {
@@ -555,18 +556,33 @@ svn_wc__conflict_skel_add_tree_conflict(
 
   tree_conflict = svn_skel__make_empty_list(result_pool);
 
-  if (reason == svn_wc_conflict_reason_moved_away
-      && move_src_op_root_abspath)
+  if (reason == svn_wc_conflict_reason_moved_away)
     {
-      const char *move_src_op_root_relpath;
+      if (move_dst_op_root_abspath)
+        {
+          const char *move_dst_op_root_relpath;
 
-      SVN_ERR(svn_wc__db_to_relpath(&move_src_op_root_relpath,
-                                    db, wri_abspath,
-                                    move_src_op_root_abspath,
-                                    result_pool, scratch_pool));
+          SVN_ERR(svn_wc__db_to_relpath(&move_dst_op_root_relpath,
+                                        db, wri_abspath,
+                                        move_dst_op_root_abspath,
+                                        result_pool, scratch_pool));
 
-      svn_skel__prepend_str(move_src_op_root_relpath, tree_conflict,
-                            result_pool);
+          svn_skel__prepend_str(move_dst_op_root_relpath, tree_conflict,
+                                result_pool);
+        }
+
+      if (move_src_op_root_abspath)
+        {
+          const char *move_src_op_root_relpath;
+
+          SVN_ERR(svn_wc__db_to_relpath(&move_src_op_root_relpath,
+                                        db, wri_abspath,
+                                        move_src_op_root_abspath,
+                                        result_pool, scratch_pool));
+
+          svn_skel__prepend_str(move_src_op_root_relpath, tree_conflict,
+                                result_pool);
+        }
     }
 
   svn_skel__prepend_str(svn_token__to_word(action_map, action),
@@ -932,6 +948,7 @@ svn_error_t *
 svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *reason,
                                     svn_wc_conflict_action_t *action,
                                     const char **move_src_op_root_abspath,
+                                    const char **move_dst_op_root_abspath,
                                     svn_wc__db_t *db,
                                     const char *wri_abspath,
                                     const svn_skel_t *conflict_skel,
@@ -981,10 +998,10 @@ svn_wc__conflict_read_tree_conflict(svn_
 
   c = c->next;
 
-  if (move_src_op_root_abspath)
+  if (move_src_op_root_abspath || move_dst_op_root_abspath)
     {
       /* Only set for update and switch tree conflicts */
-      if (c && is_moved_away)
+      if (c && is_moved_away && move_src_op_root_abspath)
         {
           const char *move_src_op_root_relpath
                             = apr_pstrmemdup(scratch_pool, c->data, c->len);
@@ -994,8 +1011,25 @@ svn_wc__conflict_read_tree_conflict(svn_
                                           move_src_op_root_relpath,
                                           result_pool, scratch_pool));
         }
-      else
+      else if (move_src_op_root_abspath)
         *move_src_op_root_abspath = NULL;
+
+      if (c)
+        c = c->next;
+
+      if (c && is_moved_away && move_dst_op_root_abspath)
+        {
+          const char *move_dst_op_root_relpath
+                            = apr_pstrmemdup(scratch_pool, c->data, c->len);
+
+          SVN_ERR(svn_wc__db_from_relpath(move_dst_op_root_abspath,
+                                          db, wri_abspath,
+                                          move_dst_op_root_relpath,
+                                          result_pool, scratch_pool));
+        }
+      else if (move_dst_op_root_abspath)
+        *move_dst_op_root_abspath = NULL;
+
     }
 
   return SVN_NO_ERROR;
@@ -1801,7 +1835,7 @@ read_tree_conflict_desc(svn_wc_conflict_
   svn_wc_conflict_action_t action;
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(
-            &reason, &action, NULL,
+            &reason, &action, NULL, NULL,
             db, local_abspath, conflict_skel, scratch_pool, scratch_pool));
 
   if (reason == svn_wc_conflict_reason_missing)
@@ -2676,7 +2710,7 @@ resolve_tree_conflict_on_node(svn_boolea
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
                                               &src_op_root_abspath,
-                                              db, local_abspath,
+                                              NULL, db, local_abspath,
                                               conflicts,
                                               scratch_pool, scratch_pool));
 
@@ -2748,6 +2782,7 @@ resolve_tree_conflict_on_node(svn_boolea
 
               SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
                                                           &src_op_root_abspath,
+                                                          NULL,
                                                           db, local_abspath,
                                                           new_conflicts,
                                                           scratch_pool,
@@ -3483,7 +3518,7 @@ svn_wc__conflict_tree_update_break_moved
     return SVN_NO_ERROR;
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
-                                              &src_op_root_abspath,
+                                              &src_op_root_abspath, NULL,
                                               wc_ctx->db, local_abspath,
                                               conflict_skel,
                                               scratch_pool, scratch_pool));
@@ -3569,7 +3604,7 @@ svn_wc__conflict_tree_update_raise_moved
   if (!tree_conflicted)
     return SVN_NO_ERROR;
 
-  SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL,
+  SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL, NULL,
                                               wc_ctx->db, local_abspath,
                                               conflict_skel,
                                               scratch_pool, scratch_pool));
@@ -3648,7 +3683,7 @@ svn_wc__conflict_tree_update_moved_away_
     return SVN_NO_ERROR;
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
-                                              &src_op_root_abspath,
+                                              &src_op_root_abspath, NULL,
                                               wc_ctx->db, local_abspath,
                                               conflict_skel,
                                               scratch_pool, scratch_pool));
@@ -3734,8 +3769,8 @@ svn_wc__conflict_tree_update_incoming_mo
     return SVN_NO_ERROR;
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&local_change, &incoming_change,
-                                              NULL, wc_ctx->db, local_abspath,
-                                              conflict_skel,
+                                              NULL, NULL, wc_ctx->db,
+                                              local_abspath, conflict_skel,
                                               scratch_pool, scratch_pool));
 
   /* Make sure the expected conflict is recorded. */
@@ -3803,8 +3838,8 @@ svn_wc__conflict_tree_update_local_add(s
     return SVN_NO_ERROR;
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&local_change, &incoming_change,
-                                              NULL, wc_ctx->db, local_abspath,
-                                              conflict_skel,
+                                              NULL, NULL, wc_ctx->db,
+                                              local_abspath, conflict_skel,
                                               scratch_pool, scratch_pool));
 
   /* Make sure the expected conflict is recorded. */

Modified: subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.h
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.h?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.h 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/conflicts.h Sat 
Mar 10 15:27:24 2018
@@ -219,6 +219,11 @@ svn_wc__conflict_skel_add_prop_conflict(
    MOVE_SRC_OP_ROOT_ABSPATH should be A for a conflict associated
    with (1), MOVE_SRC_OP_ROOT_ABSPATH should be A/B for a conflict
    associated with (2).
+   MOVE_DST_OP_ROOT_ABSPATH is the op-root of the move target (i.e. the
+   op-root of the corresponding copy). This needs to be stored because 
+   moves in the NODE table do not always persist after an update, while
+   the conflict resolver may need information about the pre-update state
+   of the move.
 
    It is an error to add another tree conflict to a conflict skel that
    already contains a tree conflict.  (It is not an error, at this level,
@@ -233,6 +238,7 @@ svn_wc__conflict_skel_add_tree_conflict(
                                         svn_wc_conflict_reason_t local_change,
                                         svn_wc_conflict_action_t 
incoming_change,
                                         const char *move_src_op_root_abspath,
+                                        const char *move_dst_op_root_abspath,
                                         apr_pool_t *result_pool,
                                         apr_pool_t *scratch_pool);
 
@@ -364,6 +370,7 @@ svn_error_t *
 svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *local_change,
                                     svn_wc_conflict_action_t *incoming_change,
                                     const char **move_src_op_root_abspath,
+                                    const char **move_dst_op_root_abspath,
                                     svn_wc__db_t *db,
                                     const char *wri_abspath,
                                     const svn_skel_t *conflict_skel,

Modified: subversion/branches/better-pristines/subversion/libsvn_wc/questions.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/questions.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/questions.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/questions.c Sat 
Mar 10 15:27:24 2018
@@ -475,7 +475,7 @@ internal_conflicted_p(svn_boolean_t *tex
           svn_wc_conflict_action_t action;
 
           SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL,
-                                                      db, local_abspath,
+                                                      NULL, db, local_abspath,
                                                       conflicts,
                                                       scratch_pool,
                                                       scratch_pool));

Modified: 
subversion/branches/better-pristines/subversion/libsvn_wc/tree_conflicts.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/tree_conflicts.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/tree_conflicts.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/tree_conflicts.c 
Sat Mar 10 15:27:24 2018
@@ -442,7 +442,7 @@ svn_wc__add_tree_conflict(svn_wc_context
                                                   conflict->local_abspath,
                                                   conflict->reason,
                                                   conflict->action,
-                                                  NULL,
+                                                  NULL, NULL,
                                                   scratch_pool, scratch_pool));
 
   switch (conflict->operation)

Modified: 
subversion/branches/better-pristines/subversion/libsvn_wc/update_editor.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/update_editor.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/update_editor.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/update_editor.c 
Sat Mar 10 15:27:24 2018
@@ -1235,9 +1235,11 @@ open_root(void *edit_baton,
     db->shadowed = TRUE;
   else if (have_work)
     {
+      const char *move_dst_op_root_abspath;
       const char *move_src_root_abspath;
 
-      SVN_ERR(svn_wc__db_base_moved_to(NULL, NULL, &move_src_root_abspath,
+      SVN_ERR(svn_wc__db_base_moved_to(NULL, &move_dst_op_root_abspath,
+                                       &move_src_root_abspath,
                                        NULL, eb->db, db->local_abspath,
                                        pool, pool));
 
@@ -1252,7 +1254,8 @@ open_root(void *edit_baton,
                     tree_conflict, eb->db, move_src_root_abspath,
                     svn_wc_conflict_reason_moved_away,
                     svn_wc_conflict_action_edit,
-                    move_src_root_abspath, pool, pool));
+                    move_src_root_abspath,
+                    move_dst_op_root_abspath, pool, pool));
 
           if (strcmp(db->local_abspath, move_src_root_abspath))
             {
@@ -1345,6 +1348,7 @@ check_tree_conflict(svn_skel_t **pconfli
   svn_wc_conflict_reason_t reason = SVN_WC_CONFLICT_REASON_NONE;
   svn_boolean_t modified = FALSE;
   const char *move_src_op_root_abspath = NULL;
+  const char *move_dst_op_root_abspath = NULL;
 
   *pconflict = NULL;
 
@@ -1397,8 +1401,8 @@ check_tree_conflict(svn_skel_t **pconfli
 
       case svn_wc__db_status_deleted:
         {
-          SVN_ERR(svn_wc__db_base_moved_to(NULL, NULL, NULL,
-                                           &move_src_op_root_abspath,
+          SVN_ERR(svn_wc__db_base_moved_to(NULL, &move_dst_op_root_abspath,
+                                           NULL, &move_src_op_root_abspath,
                                            eb->db, local_abspath,
                                            scratch_pool, scratch_pool));
           if (move_src_op_root_abspath)
@@ -1530,6 +1534,7 @@ check_tree_conflict(svn_skel_t **pconfli
                                                   reason,
                                                   action,
                                                   move_src_op_root_abspath,
+                                                  move_dst_op_root_abspath,
                                                   result_pool, scratch_pool));
 
   return SVN_NO_ERROR;
@@ -2007,11 +2012,13 @@ add_directory(const char *path,
         {
           svn_wc_conflict_reason_t reason;
           const char *move_src_op_root_abspath;
+          const char *move_dst_op_root_abspath;
           /* So this deletion wasn't just a deletion, it is actually a
              replacement. Let's install a better tree conflict. */
 
           SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL,
                                                       
&move_src_op_root_abspath,
+                                                      
&move_dst_op_root_abspath,
                                                       eb->db,
                                                       db->local_abspath,
                                                       tree_conflict,
@@ -2024,6 +2031,7 @@ add_directory(const char *path,
                                         eb->db, db->local_abspath,
                                         reason, svn_wc_conflict_action_replace,
                                         move_src_op_root_abspath,
+                                        move_dst_op_root_abspath,
                                         db->pool, scratch_pool));
 
           /* And now stop checking for conflicts here and just perform
@@ -2148,8 +2156,8 @@ add_directory(const char *path,
                                         tree_conflict,
                                         eb->db, db->local_abspath,
                                         svn_wc_conflict_reason_unversioned,
-                                        svn_wc_conflict_action_add, NULL,
-                                        db->pool, scratch_pool));
+                                        svn_wc_conflict_action_add,
+                                        NULL, NULL, db->pool, scratch_pool));
           db->edit_conflict = tree_conflict;
         }
     }
@@ -2336,7 +2344,7 @@ open_directory(const char *path,
       db->edit_conflict = tree_conflict;
       /* Other modifications wouldn't be a tree conflict */
 
-      SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL,
+      SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL, NULL,
                                                   eb->db, db->local_abspath,
                                                   tree_conflict,
                                                   db->pool, db->pool));
@@ -3220,11 +3228,13 @@ add_file(const char *path,
         {
           svn_wc_conflict_reason_t reason;
           const char *move_src_op_root_abspath;
+          const char *move_dst_op_root_abspath;
           /* So this deletion wasn't just a deletion, it is actually a
              replacement. Let's install a better tree conflict. */
 
           SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL,
                                                       
&move_src_op_root_abspath,
+                                                      
&move_dst_op_root_abspath,
                                                       eb->db,
                                                       fb->local_abspath,
                                                       tree_conflict,
@@ -3237,6 +3247,7 @@ add_file(const char *path,
                                         eb->db, fb->local_abspath,
                                         reason, svn_wc_conflict_action_replace,
                                         move_src_op_root_abspath,
+                                        move_dst_op_root_abspath,
                                         fb->pool, scratch_pool));
 
           /* And now stop checking for conflicts here and just perform
@@ -3363,7 +3374,7 @@ add_file(const char *path,
                                         eb->db, fb->local_abspath,
                                         svn_wc_conflict_reason_unversioned,
                                         svn_wc_conflict_action_add,
-                                        NULL,
+                                        NULL, NULL,
                                         fb->pool, scratch_pool));
         }
     }
@@ -3528,7 +3539,7 @@ open_file(const char *path,
       fb->edit_conflict = tree_conflict;
       /* Other modifications wouldn't be a tree conflict */
 
-      SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL,
+      SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL, NULL,
                                                   eb->db, fb->local_abspath,
                                                   tree_conflict,
                                                   scratch_pool, scratch_pool));
@@ -3797,7 +3808,7 @@ change_file_prop(void *file_baton,
                                      eb->db, fb->local_abspath,
                                      svn_wc_conflict_reason_edited,
                                      svn_wc_conflict_action_replace,
-                                     NULL,
+                                     NULL, NULL,
                                      fb->pool, scratch_pool));
 
           SVN_ERR(complete_conflict(fb->edit_conflict, fb->edit_baton,

Modified: subversion/branches/better-pristines/subversion/libsvn_wc/upgrade.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/upgrade.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/upgrade.c 
(original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/upgrade.c Sat Mar 
10 15:27:24 2018
@@ -1238,7 +1238,7 @@ svn_wc__upgrade_conflict_skel_from_raw(s
                                                       db, wri_abspath,
                                                       tc->reason,
                                                       tc->action,
-                                                      NULL,
+                                                      NULL, NULL,
                                                       scratch_pool,
                                                       scratch_pool));
 

Modified: subversion/branches/better-pristines/subversion/libsvn_wc/wc_db.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/wc_db.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- subversion/branches/better-pristines/subversion/libsvn_wc/wc_db.c (original)
+++ subversion/branches/better-pristines/subversion/libsvn_wc/wc_db.c Sat Mar 
10 15:27:24 2018
@@ -6846,7 +6846,7 @@ revert_maybe_raise_moved_away(svn_wc__db
     }
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
-                                              NULL,
+                                              NULL, NULL,
                                               db, wcroot->abspath,
                                               conflict,
                                               scratch_pool,

Modified: 
subversion/branches/better-pristines/subversion/libsvn_wc/wc_db_update_move.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/libsvn_wc/wc_db_update_move.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- 
subversion/branches/better-pristines/subversion/libsvn_wc/wc_db_update_move.c 
(original)
+++ 
subversion/branches/better-pristines/subversion/libsvn_wc/wc_db_update_move.c 
Sat Mar 10 15:27:24 2018
@@ -411,6 +411,11 @@ create_tree_conflict(svn_skel_t **confli
     ? svn_dirent_join(wcroot->abspath,
                       move_src_op_root_relpath, scratch_pool)
     : NULL;
+  const char *move_dst_op_root_abspath
+    = dst_op_root_relpath
+    ? svn_dirent_join(wcroot->abspath,
+                      dst_op_root_relpath, scratch_pool)
+    : NULL;
   const char *old_repos_relpath_part
     = old_repos_relpath && old_version
     ? svn_relpath_skip_ancestor(old_version->path_in_repos,
@@ -468,7 +473,7 @@ create_tree_conflict(svn_skel_t **confli
 
           SVN_ERR(svn_wc__conflict_read_tree_conflict(&existing_reason,
                                                       &existing_action,
-                                                      &existing_abspath,
+                                                      &existing_abspath, NULL,
                                                       db, wcroot->abspath,
                                                       conflict,
                                                       scratch_pool,
@@ -500,6 +505,7 @@ create_tree_conflict(svn_skel_t **confli
                      reason,
                      action,
                      move_src_op_root_abspath,
+                     move_dst_op_root_abspath,
                      result_pool,
                      scratch_pool));
 
@@ -4099,7 +4105,7 @@ fetch_conflict_details(int *src_op_depth
 
   SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason,
                                               action,
-                                              &move_src_op_root_abspath,
+                                              &move_src_op_root_abspath, NULL,
                                               db, local_abspath,
                                               conflict_skel, result_pool,
                                               scratch_pool));

Modified: 
subversion/branches/better-pristines/subversion/mod_authz_svn/mod_authz_svn.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/better-pristines/subversion/mod_authz_svn/mod_authz_svn.c?rev=1826407&r1=1826406&r2=1826407&view=diff
==============================================================================
--- 
subversion/branches/better-pristines/subversion/mod_authz_svn/mod_authz_svn.c 
(original)
+++ 
subversion/branches/better-pristines/subversion/mod_authz_svn/mod_authz_svn.c 
Sat Mar 10 15:27:24 2018
@@ -401,10 +401,12 @@ static svn_authz_t *
 get_access_conf(request_rec *r, authz_svn_config_rec *conf,
                 apr_pool_t *scratch_pool)
 {
+  const char *cache_key = NULL;
   const char *access_file;
   const char *groups_file;
   const char *repos_path;
   const char *repos_url = NULL;
+  void *user_data = NULL;
   svn_authz_t *access_conf = NULL;
   svn_error_t *svn_err = SVN_NO_ERROR;
   dav_error *dav_err;
@@ -464,19 +466,31 @@ get_access_conf(request_rec *r, authz_sv
                     "Path to groups file is %s", groups_file);
     }
 
-  svn_err = svn_repos_authz_read3(&access_conf,
-                                  access_file, groups_file,
-                                  TRUE, NULL,
-                                  r->connection->pool, scratch_pool);
+  cache_key = apr_pstrcat(scratch_pool, "mod_authz_svn:",
+                          access_file, groups_file, SVN_VA_NULL);
+  apr_pool_userdata_get(&user_data, cache_key, r->connection->pool);
+  access_conf = user_data;
+  if (access_conf == NULL)
+    {
+      svn_err = svn_repos_authz_read3(&access_conf, access_file,
+                                      groups_file, TRUE, NULL,
+                                      r->connection->pool,
+                                      scratch_pool);
 
-  if (svn_err)
-    {
-      log_svn_error(APLOG_MARK, r,
-                    "Failed to load the mod_authz_svn config:",
-                    svn_err, scratch_pool);
-      access_conf = NULL;
+      if (svn_err)
+        {
+          log_svn_error(APLOG_MARK, r,
+                        "Failed to load the mod_authz_svn config:",
+                        svn_err, scratch_pool);
+          access_conf = NULL;
+        }
+      else
+        {
+          /* Cache the open repos for the next request on this connection */
+          apr_pool_userdata_set(access_conf, cache_key,
+                                NULL, r->connection->pool);
+        }
     }
-
   return access_conf;
 }
 


Reply via email to