You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2015/09/30 19:22:35 UTC

svn commit: r1706091 - /subversion/trunk/subversion/libsvn_client/patch.c

Author: rhuijben
Date: Wed Sep 30 17:22:35 2015
New Revision: 1706091

URL: http://svn.apache.org/viewvc?rev=1706091&view=rev
Log:
Use the existing check for modifications in the status walker instead of
a separate later step during 'svn patch'.

* subversion/libsvn_client/patch.c
  (resolve_target_path): Remove expensive check here.
  (init_patch_target): That can be handled here for free.

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

Modified: subversion/trunk/subversion/libsvn_client/patch.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/patch.c?rev=1706091&r1=1706090&r2=1706091&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/patch.c (original)
+++ subversion/trunk/subversion/libsvn_client/patch.c Wed Sep 30 17:22:35 2015
@@ -482,6 +482,9 @@ resolve_target_path(patch_target_t *targ
       target->locally_deleted = TRUE;
     }
 
+  if (status->text_status != svn_wc_status_normal)
+    target->local_mods = TRUE;
+
   if (status && (status->kind != svn_node_unknown))
     target->db_kind = status->kind;
   else
@@ -1032,9 +1035,6 @@ init_patch_target(patch_target_t **patch
           SVN_ERR(svn_io_file_open(&target->file, target->local_abspath,
                                    APR_READ | APR_BUFFERED,
                                    APR_OS_DEFAULT, result_pool));
-          SVN_ERR(svn_wc_text_modified_p2(&target->local_mods, wc_ctx,
-                                          target->local_abspath, FALSE,
-                                          scratch_pool));
           SVN_ERR(svn_io_is_file_executable(&target->executable,
                                             target->local_abspath,
                                             scratch_pool));