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:
parent
739dbdfae4
commit
036cf4dd20
3
src/system/kernel/cache/block_cache.cpp
vendored
3
src/system/kernel/cache/block_cache.cpp
vendored
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user