From: Lars Op den Kamp Date: Mon, 18 Mar 2013 15:52:53 +0000 (+0100) Subject: alway log unhandled commands X-Git-Tag: upstream/2.2.0~1^2~4^2~13 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=3ff78be261e2a30b6cb23847f4148c1344cef8df;p=deb_libcec.git alway log unhandled commands --- diff --git a/src/lib/implementations/CECCommandHandler.cpp b/src/lib/implementations/CECCommandHandler.cpp index 1343a0c..1c1b1ff 100644 --- a/src/lib/implementations/CECCommandHandler.cpp +++ b/src/lib/implementations/CECCommandHandler.cpp @@ -756,6 +756,9 @@ void CCECCommandHandler::UnhandledCommand(const cec_command &command, const cec_ { LIB_CEC->AddLog(CEC_LOG_DEBUG, "sending abort with opcode %02x and reason '%s' to %s", command.opcode, ToString(reason), ToString(command.initiator)); m_processor->TransmitAbort(command.destination, command.initiator, command.opcode, reason); + + if (reason == CEC_ABORT_REASON_INVALID_OPERAND) + RequestEmailFromCustomer(command); } } diff --git a/src/lib/implementations/RLCommandHandler.cpp b/src/lib/implementations/RLCommandHandler.cpp index 913631b..208b504 100644 --- a/src/lib/implementations/RLCommandHandler.cpp +++ b/src/lib/implementations/RLCommandHandler.cpp @@ -108,6 +108,7 @@ int CRLCommandHandler::HandleDeviceVendorCommandWithId(const cec_command &comman case CEC_OPCODE_USER_CONTROL_PRESSED: if (command.parameters.size == 5) { + bHandled = true; switch (command.parameters[4]) { // top menu -> root menu @@ -119,10 +120,9 @@ int CRLCommandHandler::HandleDeviceVendorCommandWithId(const cec_command &comman client->SetCurrentButton(CEC_USER_CONTROL_CODE_CONTENTS_MENU); break; default: - RequestEmailFromCustomer(command); + bHandled = false; break; } - bHandled = true; } break; // user control released