Update OSXOutputPlugin.cxx
1 sec for pause is too long. we wait for the same amount of time as when ring buffer is not available for writing.
This commit is contained in:
parent
9e0fa8e9ec
commit
6d2a30b860
@ -892,11 +892,7 @@ OSXOutput::Play(const void *chunk, size_t size)
|
|||||||
std::chrono::steady_clock::duration
|
std::chrono::steady_clock::duration
|
||||||
OSXOutput::Delay() const noexcept
|
OSXOutput::Delay() const noexcept
|
||||||
{
|
{
|
||||||
// Idle if paused
|
return ring_buffer->write_available() && !pause
|
||||||
if(pause)
|
|
||||||
return std::chrono::seconds(1);
|
|
||||||
|
|
||||||
return ring_buffer->write_available()
|
|
||||||
? std::chrono::steady_clock::duration::zero()
|
? std::chrono::steady_clock::duration::zero()
|
||||||
: std::chrono::milliseconds(MPD_OSX_BUFFER_TIME_MS / 4);
|
: std::chrono::milliseconds(MPD_OSX_BUFFER_TIME_MS / 4);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user