cec: fixed - transmit an active source message when the stream path has been set...
[deb_libcec.git] / src / lib / implementations / CECCommandHandler.cpp
index c7b030543ca044a137b78e8947009e98fabb39c7..11d550c32adf7bdd6874eab1bef9d3e544e9789a 100644 (file)
@@ -464,12 +464,12 @@ bool CCECCommandHandler::HandleSetStreamPath(const cec_command &command)
     strLog.Format(">> %i sets stream path to physical address %04x", command.initiator, iStreamAddress);
     m_busDevice->AddLog(CEC_LOG_DEBUG, strLog.c_str());
 
+    /* one of the device handled by libCEC has been made active */
     CCECBusDevice *device = GetDeviceByPhysicalAddress(iStreamAddress);
-    if (device)
+    if (device && m_busDevice->MyLogicalAddressContains(device->GetLogicalAddress()))
     {
       device->SetActiveSource();
-      return device->TransmitActiveSource() &&
-          device->TransmitMenuState(command.initiator);
+      device->TransmitActiveSource();
     }
   }
   return false;