Author: hwright
Date: Thu Aug 4 21:57:48 2011
New Revision: 1154030
URL: http://svn.apache.org/viewvc?rev=1154030&view=rev
Log:
Merge r1150368 from trunk:
* r1150368
Resolve an obscure locked file problem when aborting a commit.
Justification:
Transaction cleanup should succeed or temp files will accumulate
on a server. And locks (the needle file) should be released as soon as
possible.
Notes:
rhuijben: This bug triggered my weekend search for locked files problems.
Votes:
+1: rhuijben, cmpilato, hwright
+0: danielsh (we shouldn't depend on libsvn_client fixes to avoid
accumulating tempfiles on the server)
Modified:
subversion/branches/1.7.x/ (props changed)
subversion/branches/1.7.x/STATUS
subversion/branches/1.7.x/subversion/libsvn_client/commit.c
subversion/branches/1.7.x/subversion/libsvn_client/commit_util.c
Propchange: subversion/branches/1.7.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Aug 4 21:57:48 2011
@@ -54,4 +54,4 @@
/subversion/branches/tree-conflicts:868291-873154
/subversion/branches/tree-conflicts-notify:873926-874008
/subversion/branches/uris-as-urls:1060426-1064427
-/subversion/trunk:1146013,1146121,1146219,1146222,1146274,1146492,1146555,1146606,1146620,1146684,1146781,1146832,1146834,1146870,1146899,1146904,1147293,1147309,1147882,1148071,1148131,1148374,1148424,1148566,1148588,1148853,1148877,1148882,1148936,1149105,1149141,1149160,1149228,1149240,1149343,1149371-1149372,1149377,1149398,1149401,1149539,1149572,1149627,1149675,1149701,1149713,1150242,1150372,1150441,1150506,1150812,1150853,1151036,1151177,1151610,1151911,1152129,1152140,1152282,1152726,1153416,1153799,1153807,1153968
+/subversion/trunk:1146013,1146121,1146219,1146222,1146274,1146492,1146555,1146606,1146620,1146684,1146781,1146832,1146834,1146870,1146899,1146904,1147293,1147309,1147882,1148071,1148131,1148374,1148424,1148566,1148588,1148853,1148877,1148882,1148936,1149105,1149141,1149160,1149228,1149240,1149343,1149371-1149372,1149377,1149398,1149401,1149539,1149572,1149627,1149675,1149701,1149713,1150242,1150368,1150372,1150441,1150506,1150812,1150853,1151036,1151177,1151610,1151911,1152129,1152140,1152282,1152726,1153416,1153799,1153807,1153968
Modified: subversion/branches/1.7.x/STATUS
URL:
http://svn.apache.org/viewvc/subversion/branches/1.7.x/STATUS?rev=1154030&r1=1154029&r2=1154030&view=diff
==============================================================================
--- subversion/branches/1.7.x/STATUS (original)
+++ subversion/branches/1.7.x/STATUS Thu Aug 4 21:57:48 2011
@@ -188,16 +188,3 @@ Approved changes:
Votes:
+1: rhuijben, gstein, hwright
+0: danielsh
-
- * r1150368
- Resolve an obscure locked file problem when aborting a commit.
- Justification:
- Transaction cleanup should succeed or temp files will accumulate
- on a server. And locks (the needle file) should be released as soon as
- possible.
- Notes:
- rhuijben: This bug triggered my weekend search for locked files problems.
- Votes:
- +1: rhuijben, cmpilato, hwright
- +0: danielsh (we shouldn't depend on libsvn_client fixes to avoid
- accumulating tempfiles on the server)
Modified: subversion/branches/1.7.x/subversion/libsvn_client/commit.c
URL:
http://svn.apache.org/viewvc/subversion/branches/1.7.x/subversion/libsvn_client/commit.c?rev=1154030&r1=1154029&r2=1154030&view=diff
==============================================================================
--- subversion/branches/1.7.x/subversion/libsvn_client/commit.c (original)
+++ subversion/branches/1.7.x/subversion/libsvn_client/commit.c Thu Aug 4
21:57:48 2011
@@ -1451,6 +1451,7 @@ svn_client_commit5(const apr_array_heade
cleanup:
/* Abort the commit if it is still in progress. */
+ svn_pool_clear(iterpool); /* Close open handles before aborting */
if (commit_in_progress)
svn_error_clear(editor->abort_edit(edit_baton, pool));
Modified: subversion/branches/1.7.x/subversion/libsvn_client/commit_util.c
URL:
http://svn.apache.org/viewvc/subversion/branches/1.7.x/subversion/libsvn_client/commit_util.c?rev=1154030&r1=1154029&r2=1154030&view=diff
==============================================================================
--- subversion/branches/1.7.x/subversion/libsvn_client/commit_util.c (original)
+++ subversion/branches/1.7.x/subversion/libsvn_client/commit_util.c Thu Aug 4
21:57:48 2011
@@ -1845,11 +1845,14 @@ svn_client__do_commit(const char *base_u
result_pool, iterpool);
if (err)
- return svn_error_trace(fixup_commit_error(item->path,
- base_url,
- item->session_relpath,
- svn_node_file,
- err, ctx, iterpool));
+ {
+ svn_pool_destroy(iterpool); /* Close tempfiles */
+ return svn_error_trace(fixup_commit_error(item->path,
+ base_url,
+ item->session_relpath,
+ svn_node_file,
+ err, ctx, scratch_pool));
+ }
if (md5_checksums)
apr_hash_set(*md5_checksums, item->path, APR_HASH_KEY_STRING,