cosmetics
[deb_libcec.git] / src / lib / implementations / CECCommandHandler.cpp
index be2a9bd661bc322b1645e0417fcee7180900fb10..3906060691712eb822137a5c0dc2978b7e433351 100644 (file)
@@ -931,11 +931,12 @@ bool CCECCommandHandler::InitHandler(void)
 {
   if (m_busDevice->GetLogicalAddress() == CECDEVICE_TV)
   {
-    CCECBusDevice *primary = m_processor->m_busDevices[m_processor->GetLogicalAddresses().primary];
+    CCECBusDevice *primary = m_processor->GetPrimaryDevice();
     primary->SetPowerStatus(CEC_POWER_STATUS_ON);
     primary->SetMenuState(CEC_MENU_STATE_ACTIVATED);
 
     m_processor->SetActiveSource();
     primary->TransmitMenuState(m_busDevice->GetLogicalAddress());
   }
+  return true;
 }