cec: check whether the port is open, not whether libCEC is initialised in Transmit()
authorLars Op den Kamp <lars@opdenkamp.eu>
Thu, 16 Feb 2012 09:57:26 +0000 (10:57 +0100)
committerLars Op den Kamp <lars@opdenkamp.eu>
Thu, 16 Feb 2012 09:57:26 +0000 (10:57 +0100)
src/lib/CECProcessor.cpp

index f9d21346f2dbceaec74dfa2862df5808fbb6cd97..643defad7cf17746f0fe4b452fd740353e6f631c 100644 (file)
@@ -869,7 +869,7 @@ bool CCECProcessor::Transmit(const cec_command &data)
     CLockObject lock(m_mutex);
     LogOutput(data);
     m_iLastTransmission = GetTimeMs();
-    if (!m_communication || !IsInitialised())
+    if (!m_communication || !m_communication->IsOpen())
     {
       CLibCEC::AddLog(CEC_LOG_ERROR, "cannot transmit command: connection closed");
       return false;