subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1442571 - /subversion/trunk/subversion/libsvn_client/merge.c
Date Tue, 05 Feb 2013 13:04:36 GMT
Author: rhuijben
Date: Tue Feb  5 13:04:35 2013
New Revision: 1442571

URL: http://svn.apache.org/viewvc?rev=1442571&view=rev
Log:
* subversion/libsvn_client/merge.c
  (do_merge): Calculate the resulting set of modified paths once, instead of
    for every loop invocation. We don't reset these lists, so the result is
    unaffected. The answer to the old question why we didn't do this for files
    is that we don't really test reintegrate on files thorougly.

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

Modified: subversion/trunk/subversion/libsvn_client/merge.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/merge.c?rev=1442571&r1=1442570&r2=1442571&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/merge.c (original)
+++ subversion/trunk/subversion/libsvn_client/merge.c Tue Feb  5 13:04:35 2013
@@ -9517,27 +9517,6 @@ do_merge(apr_hash_t **modified_subtrees,
                                      abort_on_conflicts,
                                      &merge_cmd_baton,
                                      iterpool));
-
-          /* Does the caller want to know what the merge has done? */
-          /* ### Why only if the target is a dir and not a file? */
-          if (modified_subtrees)
-            {
-              *modified_subtrees =
-                  apr_hash_overlay(result_pool, *modified_subtrees,
-                                   merge_cmd_baton.merged_abspaths);
-              *modified_subtrees =
-                  apr_hash_overlay(result_pool, *modified_subtrees,
-                                   merge_cmd_baton.added_abspaths);
-              *modified_subtrees =
-                  apr_hash_overlay(result_pool, *modified_subtrees,
-                                   merge_cmd_baton.deleted_abspaths);
-              *modified_subtrees =
-                  apr_hash_overlay(result_pool, *modified_subtrees,
-                                   merge_cmd_baton.skipped_abspaths);
-              *modified_subtrees =
-                  apr_hash_overlay(result_pool, *modified_subtrees,
-                                   merge_cmd_baton.tree_conflicted_abspaths);
-            }
         }
 
       /* The final mergeinfo on TARGET_WCPATH may itself elide. */
@@ -9549,6 +9528,26 @@ do_merge(apr_hash_t **modified_subtrees,
   /* Let everyone know we're finished here. */
   notify_merge_completed(target->abspath, ctx, iterpool);
 
+    /* Does the caller want to know what the merge has done? */
+  if (modified_subtrees)
+    {
+      *modified_subtrees =
+          apr_hash_overlay(result_pool, *modified_subtrees,
+                           merge_cmd_baton.merged_abspaths);
+      *modified_subtrees =
+          apr_hash_overlay(result_pool, *modified_subtrees,
+                           merge_cmd_baton.added_abspaths);
+      *modified_subtrees =
+          apr_hash_overlay(result_pool, *modified_subtrees,
+                           merge_cmd_baton.deleted_abspaths);
+      *modified_subtrees =
+          apr_hash_overlay(result_pool, *modified_subtrees,
+                           merge_cmd_baton.skipped_abspaths);
+      *modified_subtrees =
+          apr_hash_overlay(result_pool, *modified_subtrees,
+                           merge_cmd_baton.tree_conflicted_abspaths);
+    }
+
   if (src_session)
     SVN_ERR(svn_ra_reparent(src_session, old_src_session_url, iterpool));
 



Mime
View raw message