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 2011/01/11 18:51:35 UTC

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

Author: stsp
Date: Tue Jan 11 17:51:34 2011
New Revision: 1057769

URL: http://svn.apache.org/viewvc?rev=1057769&view=rev
Log:
* subversion/libsvn_client/patch.c
  (apply_one_patch): Allow cancellation during apply/reject hunks step.
  (install_patched_prop_targets): Move oddly placed cancellation call to
   a more appropriate place (start of the outer loop).

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=1057769&r1=1057768&r2=1057769&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/patch.c (original)
+++ subversion/trunk/subversion/libsvn_client/patch.c Tue Jan 11 17:51:34 2011
@@ -1701,6 +1701,9 @@ apply_one_patch(patch_target_t **patch_t
 
       svn_pool_clear(iterpool);
 
+      if (cancel_func)
+        SVN_ERR((cancel_func)(cancel_baton));
+
       hi = APR_ARRAY_IDX(target->content_info->hunks, i, hunk_info_t *);
       if (hi->already_applied)
         continue;
@@ -2211,6 +2214,9 @@ install_patched_prop_targets(patch_targe
 
       svn_pool_clear(iterpool);
 
+      if (ctx->cancel_func)
+        SVN_ERR(ctx->cancel_func(ctx->cancel_baton));
+
       /* For a deleted prop we only set the value to NULL. */
       if (prop_target->operation == svn_diff_op_deleted)
         {
@@ -2267,8 +2273,6 @@ install_patched_prop_targets(patch_targe
             {
               SVN_ERR(svn_io_file_create(target->local_abspath, "",
                                          scratch_pool));
-              if (ctx->cancel_func)
-                SVN_ERR(ctx->cancel_func(ctx->cancel_baton));
               SVN_ERR(svn_wc_add_from_disk(ctx->wc_ctx, target->local_abspath,
                                            /* suppress notification */
                                            NULL, NULL,