storage/nfs: use class ScopeUnlock
This commit is contained in:
parent
0e48747607
commit
84c406d5f5
|
@ -173,9 +173,11 @@ private:
|
|||
switch (state) {
|
||||
case State::INITIAL:
|
||||
/* schedule connect */
|
||||
mutex.unlock();
|
||||
defer_connect.Schedule();
|
||||
mutex.lock();
|
||||
{
|
||||
const ScopeUnlock unlock(mutex);
|
||||
defer_connect.Schedule();
|
||||
}
|
||||
|
||||
if (state == State::INITIAL)
|
||||
cond.wait(mutex);
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue