cec: check whether the port is open, not whether libCEC is initialised in Transmit()
[deb_libcec.git] / src / lib / platform / util / timeutils.h
index 985712a78b8cd4acd377555b02396aa2e7402551..3b1ef700c8f4213ca1a1f2af3ee15e5e6f5d71e7 100644 (file)
@@ -113,10 +113,10 @@ namespace PLATFORM
     bool IsSet(void) const       { return m_iTarget > 0; }
     void Init(uint32_t iTimeout) { m_iTarget = GetTimeMs() + iTimeout; }
 
-    uint64_t TimeLeft(void) const
+    uint32_t TimeLeft(void) const
     {
       uint64_t iNow = GetTimeMs();
-      return (iNow > m_iTarget) ? 0 : m_iTarget - iNow;
+      return (iNow > m_iTarget) ? 0 : (uint32_t)(m_iTarget - iNow);
     }
 
   private: