block_cache_delete(): only lock the cache mutex and avoid MutexLocker. the mutex is destroyed in the destructor.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25467 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2008-05-12 12:56:59 +00:00
parent 739dbdfae4
commit 036cf4dd20

View File

@ -2189,7 +2189,7 @@ block_cache_delete(void *_cache, bool allowWrites)
if (allowWrites)
block_cache_sync(cache);
MutexLocker locker(&cache->lock);
mutex_lock(&cache->lock);
// free all blocks
@ -2209,7 +2209,6 @@ block_cache_delete(void *_cache, bool allowWrites)
delete transaction;
}
locker.Unlock();
delete cache;
}