X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Flib%2Fimplementations%2FCECCommandHandler.cpp;h=5fe3ebae6156aabd4c35812e882dffff33431e44;hb=4478bc797f871f631399ab8008d3b2787ded07c2;hp=66bdfbd10b509f150df19d8a648024519c08767d;hpb=cb2397e953b3f892b4206d5bb87968ca4cccbac8;p=deb_libcec.git diff --git a/src/lib/implementations/CECCommandHandler.cpp b/src/lib/implementations/CECCommandHandler.cpp index 66bdfbd..5fe3eba 100644 --- a/src/lib/implementations/CECCommandHandler.cpp +++ b/src/lib/implementations/CECCommandHandler.cpp @@ -959,12 +959,11 @@ bool CCECCommandHandler::Transmit(cec_command &command, bool bExpectResponse /* while (!bReturn && ++iTries <= iMaxTries) { m_expectedResponse = expectedResponse; - if (m_processor->Transmit(command)) + if ((bReturn = m_processor->Transmit(command))) { CLibCEC::AddLog(CEC_LOG_DEBUG, "command transmitted"); - bReturn = bExpectResponse ? - m_condition.Wait(m_receiveMutex, m_iTransmitWait) : - true; + if (bExpectResponse) + bReturn = m_condition.Wait(m_receiveMutex, m_iTransmitWait); } } --m_iUseCounter;