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 2014/03/11 18:00:20 UTC
svn commit: r1576427 - /subversion/trunk/subversion/libsvn_fs_fs/pack.c
Author: stefan2
Date: Tue Mar 11 17:00:19 2014
New Revision: 1576427
URL: http://svn.apache.org/r1576427
Log:
* subversion/libsvn_fs_fs/pack.c
(svn_fs_fs__pack): Give a rationale for using a sub-pool. No functional change.
Suggested by: ivan
Modified:
subversion/trunk/subversion/libsvn_fs_fs/pack.c
Modified: subversion/trunk/subversion/libsvn_fs_fs/pack.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/pack.c?rev=1576427&r1=1576426&r2=1576427&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_fs/pack.c (original)
+++ subversion/trunk/subversion/libsvn_fs_fs/pack.c Tue Mar 11 17:00:19 2014
@@ -2017,7 +2017,12 @@ svn_fs_fs__pack(svn_fs_t *fs,
if (ffd->format >= SVN_FS_FS__MIN_PACK_LOCK_FORMAT)
{
/* Newer repositories provide a pack operation specific lock.
- Acquire it to prevent concurrent packs. */
+ Acquire it to prevent concurrent packs.
+
+ Since the file lock's lifetime is bound to a pool, we create a
+ separate subpool here to release the lock immediately after the
+ operation finished.
+ */
apr_pool_t *subpool = svn_pool_create(pool);
const char *lock_path = svn_dirent_join(fs->path, PATH_PACK_LOCK_FILE,
subpool);