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

Commit 5894ee95 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add a missing null pointer check in the codec config comparison logic" into pi-dev

parents f42ab6d1 55f76e39
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -631,12 +631,13 @@ final class A2dpStateMachine extends StateMachine {
            if ((prevCodecConfig != null)
                    && (prevCodecConfig.getCodecType() != newCodecConfig.getCodecType())) {
                update = true;
            }
            if (!newCodecConfig.sameAudioFeedingParameters(prevCodecConfig)) {
            } else if (!newCodecConfig.sameAudioFeedingParameters(prevCodecConfig)) {
                update = true;
            }
            if ((newCodecConfig.getCodecType() == BluetoothCodecConfig.SOURCE_CODEC_TYPE_LDAC)
                    && prevCodecConfig.getCodecSpecific1() != newCodecConfig.getCodecSpecific1()) {
            } else if ((newCodecConfig.getCodecType()
                        == BluetoothCodecConfig.SOURCE_CODEC_TYPE_LDAC)
                    && (prevCodecConfig != null)
                    && (prevCodecConfig.getCodecSpecific1()
                        != newCodecConfig.getCodecSpecific1())) {
                update = true;
            }
            if (update) {