fixed: don't call CEC_ALERT_CONNECTION_LOST when closing the connection, which caused...
authorLars Op den Kamp <lars@opdenkamp.eu>
Tue, 28 Oct 2014 12:48:02 +0000 (13:48 +0100)
committerLars Op den Kamp <lars@opdenkamp.eu>
Tue, 28 Oct 2014 12:48:39 +0000 (13:48 +0100)
ChangeLog
debian/changelog
src/lib/adapter/Pulse-Eight/USBCECAdapterCommunication.cpp

index 0cc765e6e06bf09b87ce328ee6ea634c6e4ae98d..862c347b339b459867e8d5d7049d59c1ba94dd8a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -13,6 +13,7 @@ libcec (2.2.0-1) unstable; urgency=low
       credits: @ksooo
     * LibCecTray: keypress not sent when multiple instances of eshell.exe are
       running. thanks @pvanbaren
+    * deadlock on exit in XBMC, because of CEC_ALERT_CONNECTION_LOST
 
  -- Pulse-Eight Packaging <packaging@pulse-eight.com>  Tue, 28 Oct 2014 10:45:00 +0200
 
index 0cc765e6e06bf09b87ce328ee6ea634c6e4ae98d..862c347b339b459867e8d5d7049d59c1ba94dd8a 100644 (file)
@@ -13,6 +13,7 @@ libcec (2.2.0-1) unstable; urgency=low
       credits: @ksooo
     * LibCecTray: keypress not sent when multiple instances of eshell.exe are
       running. thanks @pvanbaren
+    * deadlock on exit in XBMC, because of CEC_ALERT_CONNECTION_LOST
 
  -- Pulse-Eight Packaging <packaging@pulse-eight.com>  Tue, 28 Oct 2014 10:45:00 +0200
 
index 037359599be766fce14a87779e3405318393927f..1be07c51fbb385e224a7fa5ec1ff0c2cb40515f9 100644 (file)
@@ -710,7 +710,7 @@ void *CAdapterPingThread::Process(void)
       /* send a ping to the adapter */
       bool bPinged(false);
       int iFailedCounter(0);
-      while (!bPinged && iFailedCounter < 3)
+      while (!bPinged && iFailedCounter < 3 && !IsStopped())
       {
         if (!m_com->PingAdapter())
         {
@@ -724,7 +724,7 @@ void *CAdapterPingThread::Process(void)
         }
       }
 
-      if (iFailedCounter == 3)
+      if (iFailedCounter == 3 && !IsStopped())
       {
         /* failed to ping the adapter 3 times in a row. something must be wrong with the connection */
         m_com->LIB_CEC->AddLog(CEC_LOG_ERROR, "failed to ping the adapter 3 times in a row. closing the connection.");