peekFrameLength() should abide by mutex locks on txQueue's;

pull/69/head
Bryan Biedenkapp 1 year ago
parent c60f418ddc
commit 89a1d4bde9

@ -312,6 +312,8 @@ bool Slot::processFrame(uint8_t *data, uint32_t len)
uint32_t Slot::peekFrameLength()
{
std::lock_guard<std::mutex> lock(m_queueLock);
if (m_txQueue.isEmpty() && m_txImmQueue.isEmpty())
return 0U;

@ -465,6 +465,8 @@ bool Control::processFrame(uint8_t* data, uint32_t len)
uint32_t Control::peekFrameLength()
{
std::lock_guard<std::mutex> lock(m_queueLock);
if (m_txQueue.isEmpty() && m_txImmQueue.isEmpty())
return 0U;

@ -674,6 +674,8 @@ bool Control::processFrame(uint8_t* data, uint32_t len)
uint32_t Control::peekFrameLength()
{
std::lock_guard<std::mutex> lock(m_queueLock);
if (m_txQueue.isEmpty() && m_txImmQueue.isEmpty())
return 0U;

Loading…
Cancel
Save

Powered by TurnKey Linux.