From 19b2a82fb3292839ce9b66e916c0c3b51332b7b4 Mon Sep 17 00:00:00 2001 From: Lars Op den Kamp Date: Thu, 21 Jun 2012 11:16:32 +0200 Subject: [PATCH] cec: get the cached power status of a device in CVLCommandHandler::PowerUpEventReceived() instead of the current one, or it might send a CEC command to a device which is expecting a reply to another command --- src/lib/implementations/VLCommandHandler.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/lib/implementations/VLCommandHandler.cpp b/src/lib/implementations/VLCommandHandler.cpp index aadf988..642b383 100644 --- a/src/lib/implementations/VLCommandHandler.cpp +++ b/src/lib/implementations/VLCommandHandler.cpp @@ -159,14 +159,8 @@ bool CVLCommandHandler::PowerUpEventReceived(void) return true; } - cec_logical_address sourceLA = m_busDevice->GetLogicalAddress(); - if (sourceLA == CECDEVICE_TV) - sourceLA = m_processor->GetPrimaryDevice()->GetLogicalAddress(); - - cec_power_status powerStatus = m_busDevice->GetPowerStatus(sourceLA); - CLockObject lock(m_mutex); - m_bPowerUpEventReceived = (powerStatus == CEC_POWER_STATUS_ON); + m_bPowerUpEventReceived = (m_busDevice->GetCurrentPowerStatus() == CEC_POWER_STATUS_ON); return m_bPowerUpEventReceived; } -- 2.34.1