mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-19 20:19:13 +12:00
Make max ring buffer timeout smaller
This commit is contained in:
parent
921250bcd2
commit
35b3e2b401
1 changed files with 1 additions and 2 deletions
|
@ -35,7 +35,6 @@ SOFTWARE.
|
|||
#include <stdexcept>
|
||||
|
||||
namespace Common {
|
||||
|
||||
template <typename T, size_t BS = 1024>
|
||||
class RingBuffer {
|
||||
|
||||
|
@ -56,7 +55,7 @@ namespace Common {
|
|||
}
|
||||
std::unique_lock<std::mutex> l(m_mu);
|
||||
using namespace std::chrono_literals;
|
||||
bool safe = m_cv.wait_for(l, 20ms, [this, N]() -> bool { return N < availableLocked(); });
|
||||
bool safe = m_cv.wait_for(l, 5ms, [this, N]() -> bool { return N < availableLocked(); });
|
||||
if (safe) enqueueSafe(data, N);
|
||||
return safe;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue