player/Thread: eliminate LockWaitDecoderStartup()

This commit is contained in:
Max Kellermann 2017-12-22 00:58:42 +01:00
parent 1f0770ca55
commit 08b4a7aaf2
1 changed files with 2 additions and 6 deletions

View File

@ -231,11 +231,6 @@ private:
return true;
}
bool LockWaitDecoderStartup() noexcept {
const std::lock_guard<Mutex> lock(pc.mutex);
return WaitDecoderStartup();
}
/**
* Stop the decoder and clears (and frees) its music pipe.
*
@ -641,7 +636,8 @@ Player::SeekDecoder() noexcept
StartDecoder(*pipe);
ActivateDecoder();
if (!LockWaitDecoderStartup())
const std::lock_guard<Mutex> lock(pc.mutex);
if (!WaitDecoderStartup())
return false;
} else {
if (!IsDecoderAtCurrentSong()) {