subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hwri...@apache.org
Subject svn commit: r1350590 - /subversion/trunk/subversion/libsvn_repos/replay.c
Date Fri, 15 Jun 2012 11:59:49 GMT
Author: hwright
Date: Fri Jun 15 11:59:48 2012
New Revision: 1350590

URL: http://svn.apache.org/viewvc?rev=1350590&view=rev
Log:
* subversion/libsvn_repos/replay.c
  (svn_repos__replay_ev2): Abort the editor on errors.

Modified:
    subversion/trunk/subversion/libsvn_repos/replay.c

Modified: subversion/trunk/subversion/libsvn_repos/replay.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_repos/replay.c?rev=1350590&r1=1350589&r2=1350590&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_repos/replay.c (original)
+++ subversion/trunk/subversion/libsvn_repos/replay.c Fri Jun 15 11:59:48 2012
@@ -1451,6 +1451,7 @@ svn_repos__replay_ev2(svn_fs_root_t *roo
   apr_array_header_t *paths;
   apr_array_header_t *copies;
   apr_pool_t *iterpool;
+  svn_error_t *err = SVN_NO_ERROR;
   int i;
 
   SVN_ERR_ASSERT(!svn_dirent_is_absolute(base_repos_relpath));
@@ -1533,15 +1534,18 @@ svn_repos__replay_ev2(svn_fs_root_t *roo
       const char *repos_relpath = APR_ARRAY_IDX(paths, i, const char *);
 
       svn_pool_clear(iterpool);
-      SVN_ERR(replay_node(root, repos_relpath, editor,
-                          low_water_mark,
-                          base_repos_relpath, copies, changed_paths,
-                          authz_read_func, authz_read_baton,
-                          scratch_pool, iterpool));
+      err = replay_node(root, repos_relpath, editor, low_water_mark,
+                        base_repos_relpath, copies, changed_paths,
+                        authz_read_func, authz_read_baton,
+                        scratch_pool, iterpool);
+      if (err)
+        break;
     }
 
-  /* ### We should probably abort on an error condition. */
-  SVN_ERR(svn_editor_complete(editor));
+  if (err)
+    return svn_error_compose_create(err, svn_editor_abort(editor));
+  else
+    SVN_ERR(svn_editor_complete(editor));
 
   svn_pool_destroy(iterpool);
   return SVN_NO_ERROR;



Mime
View raw message