subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stef...@apache.org
Subject svn commit: r1727790 - /subversion/trunk/subversion/mod_dav_svn/merge.c
Date Sun, 31 Jan 2016 10:28:30 GMT
Author: stefan2
Date: Sun Jan 31 10:28:30 2016
New Revision: 1727790

URL: http://svn.apache.org/viewvc?rev=1727790&view=rev
Log:
Reduce memory consumption of DAV merge responses (commits).

* subversion/mod_dav_svn/merge.c
  (do_resources): Since the paths in the changes list provided by the FS
                  are already unique, we only need to track thoes that
                  might clash with ones we add ourselves.

Modified:
    subversion/trunk/subversion/mod_dav_svn/merge.c

Modified: subversion/trunk/subversion/mod_dav_svn/merge.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/mod_dav_svn/merge.c?rev=1727790&r1=1727789&r2=1727790&view=diff
==============================================================================
--- subversion/trunk/subversion/mod_dav_svn/merge.c (original)
+++ subversion/trunk/subversion/mod_dav_svn/merge.c Sun Jan 31 10:28:30 2016
@@ -178,7 +178,14 @@ do_resources(const dav_svn_repos *repos,
               SVN_ERR(send_response(repos, root, path,
                                     kind == svn_node_dir,
                                     output, bb, subpool));
-              apr_hash_set(sent, path, path_len, (void *)1);
+
+              /* The paths in CHANGES are unique, i.e. they can only
+               * clash with those that we end in the SEND_PARENT case.
+               *
+               * Because file paths cannot be the parent of other paths,
+               * we only need to track non-file paths. */
+              if (change->node_kind != svn_node_file)
+                apr_hash_set(sent, path, path_len, (void *)1);
             }
         }
       if (send_parent)



Mime
View raw message