cec: don't try to do anything before the processor thread has started
[deb_libcec.git] / src / lib / AdapterCommunication.cpp
index 5541bf56a5381febe2a64264b897099fff2d1cc6..54077d6ed776b4b6ef72f0dcc0d76cffd948ab45 100644 (file)
@@ -43,7 +43,6 @@ using namespace CEC;
 CCECAdapterMessage::CCECAdapterMessage(const cec_command &command)
 {
   clear();
-  maxTries = command.retries + 1;
 
   //set ack polarity to high when transmitting to the broadcast address
   //set ack polarity low when transmitting to any other address
@@ -328,6 +327,10 @@ void *CAdapterCommunication::Process(void)
     WriteNextCommand();
   }
 
+  CCECAdapterMessage *msg;
+  if (m_outBuffer.Pop(msg))
+    msg->condition.Broadcast();
+
   return NULL;
 }