Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a8fd44b7 authored by Jinsuk Kim's avatar Jinsuk Kim Committed by Jungshik Jang
Browse files

DO NOT MERGE: Fix a couple of bugs in CEC services

- Correct conversion for byte to int for cec opcode
- Use the right Handler.obtainMessage() to pass an integer variable

Change-Id: Ie3e86225f1702decce454aeb197911a371f51c17
parent 304b4a72
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -46,7 +46,7 @@ public final class HdmiCecMessage implements Parcelable {
    public HdmiCecMessage(int source, int destination, int opcode, byte[] params) {
        mSource = source;
        mDestination = destination;
        mOpcode = opcode;
        mOpcode = opcode & 0xFF;
        mParams = Arrays.copyOf(params, params.length);
    }

+2 −1
Original line number Diff line number Diff line
@@ -133,7 +133,8 @@ abstract class FeatureAction {

        @Override
        public void sendTimerMessage(int state, long delayMillis) {
            sendMessageDelayed(obtainMessage(MSG_TIMEOUT, state), delayMillis);
            // The third argument(0) is not used.
            sendMessageDelayed(obtainMessage(MSG_TIMEOUT, state, 0), delayMillis);
        }

        @Override