cec: also add commands to unsupported features when receiving CEC_ABORT_REASON_REFUSED
[deb_libcec.git] / src / lib / implementations / CECCommandHandler.cpp
index d2fe2fd9f742101948ceb97b08c5cbbab3a55fc6..a9b4c40c57f2c7f483b9e1036ee60357a233fc88 100644 (file)
@@ -242,7 +242,9 @@ bool CCECCommandHandler::HandleDeviceVendorId(const cec_command &command)
 
 bool CCECCommandHandler::HandleFeatureAbort(const cec_command &command)
 {
-  if (command.parameters.size == 2 && command.parameters[1] == CEC_ABORT_REASON_UNRECOGNIZED_OPCODE)
+  if (command.parameters.size == 2 &&
+        (command.parameters[1] == CEC_ABORT_REASON_UNRECOGNIZED_OPCODE ||
+         command.parameters[1] == CEC_ABORT_REASON_REFUSED))
     m_processor->m_busDevices[command.initiator]->SetUnsupportedFeature((cec_opcode)command.parameters[0]);
   return true;
 }