Removed the possibility to create a Semaphore object without specifying
a name - that's mostly done to: 1) force better fitting lock names 2) make the API consistent (the empty ReadWriteLock constructor doesn't initialize the lock anymore). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3366 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -312,6 +312,7 @@ AllocationGroup::Free(Transaction *transaction, uint16 start, int32 length)
|
|||||||
BlockAllocator::BlockAllocator(Volume *volume)
|
BlockAllocator::BlockAllocator(Volume *volume)
|
||||||
:
|
:
|
||||||
fVolume(volume),
|
fVolume(volume),
|
||||||
|
fLock("bfs allocator"),
|
||||||
fGroups(NULL),
|
fGroups(NULL),
|
||||||
fCheckBitmap(NULL)
|
fCheckBitmap(NULL)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,7 +29,7 @@
|
|||||||
|
|
||||||
class Semaphore {
|
class Semaphore {
|
||||||
public:
|
public:
|
||||||
Semaphore(const char *name = "bfs sem")
|
Semaphore(const char *name)
|
||||||
:
|
:
|
||||||
#ifdef USE_BENAPHORE
|
#ifdef USE_BENAPHORE
|
||||||
fSemaphore(create_sem(0, name)),
|
fSemaphore(create_sem(0, name)),
|
||||||
@@ -151,14 +151,14 @@ class ReadWriteLock {
|
|||||||
public:
|
public:
|
||||||
ReadWriteLock(const char *name)
|
ReadWriteLock(const char *name)
|
||||||
:
|
:
|
||||||
fWriteLock()
|
fWriteLock(name)
|
||||||
{
|
{
|
||||||
Initialize(name);
|
Initialize(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
ReadWriteLock()
|
ReadWriteLock()
|
||||||
:
|
:
|
||||||
fWriteLock()
|
fWriteLock("bfs r/w w-lock")
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user