subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From phi...@apache.org
Subject svn commit: r1182492 - /subversion/trunk/subversion/libsvn_fs_base/bdb/env.c
Date Wed, 12 Oct 2011 17:46:19 GMT
Author: philip
Date: Wed Oct 12 17:46:19 2011
New Revision: 1182492

URL: http://svn.apache.org/viewvc?rev=1182492&view=rev
Log:
Fix the BDB regression tests with svn_mutex__t.

* subversion/libsvn_fs_base/bdb/env.c
  (clear_cache): Null the mutex to prevent attempts to use it after
   it has been destroyed.
  (svn_fs_bdb__close): Add comment.

Modified:
    subversion/trunk/subversion/libsvn_fs_base/bdb/env.c

Modified: subversion/trunk/subversion/libsvn_fs_base/bdb/env.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_base/bdb/env.c?rev=1182492&r1=1182491&r2=1182492&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_base/bdb/env.c (original)
+++ subversion/trunk/subversion/libsvn_fs_base/bdb/env.c Wed Oct 12 17:46:19 2011
@@ -367,6 +367,7 @@ static apr_status_t
 clear_cache(void *data)
 {
   bdb_cache = NULL;
+  bdb_cache_lock = NULL;
   return APR_SUCCESS;
 }
 
@@ -540,6 +541,7 @@ svn_fs_bdb__close(bdb_env_baton_t *bdb_b
 #endif
     }
 
+  /* This may run during final pool cleanup when the lock is NULL. */
   SVN_MUTEX__WITH_LOCK(bdb_cache_lock, svn_fs_bdb__close_internal(bdb));
   
   return SVN_NO_ERROR;



Mime
View raw message