RequestOwner::Wait(): No need to publish the condition variable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35574 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -416,12 +416,12 @@ RequestOwner::Wait(bool interruptable, bigtime_t timeout)
|
||||
|
||||
// publish the condition variable
|
||||
ConditionVariable conditionVariable;
|
||||
conditionVariable.Publish(this, "tty request");
|
||||
conditionVariable.Init(this, "tty request");
|
||||
fConditionVariable = &conditionVariable;
|
||||
|
||||
// add an entry to wait on
|
||||
ConditionVariableEntry entry;
|
||||
entry.Add(this);
|
||||
conditionVariable.Add(&entry);
|
||||
|
||||
locker.Unlock();
|
||||
|
||||
@@ -438,7 +438,6 @@ RequestOwner::Wait(bool interruptable, bigtime_t timeout)
|
||||
// remove the condition variable
|
||||
locker.Lock();
|
||||
fConditionVariable = NULL;
|
||||
conditionVariable.Unpublish();
|
||||
}
|
||||
|
||||
// get the result
|
||||
|
||||
Reference in New Issue
Block a user