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

Commit d8413260 authored by Tyler Gunn's avatar Tyler Gunn
Browse files

Prevent preciseCallStateChanged from firing for media capabilities change.

In processCallStateChanged, there was the potential for
"notifyPreciseCallStateChanged()" to be called, even if ignoreState was
true.  Moved the code for invoking the precise call state changed
callback into the "else" clause of the conditional.

Bug: 22564433
Change-Id: Ib2a05bd5f592005d57623812c6cd40c2bfcbf253
parent 6791ced4
Loading
Loading
Loading
Loading
+10 −9
Original line number Diff line number Diff line
@@ -940,8 +940,10 @@ public final class ImsPhoneCallTracker extends CallTracker {
        // State updates will be triggered through individual callbacks
        // i.e. onCallHeld, onCallResume, etc and conn.update will be responsible for the update
        if (ignoreState) {
            changed = conn.updateMediaCapabilities(imsCall);
        } else {
            conn.updateMediaCapabilities(imsCall);
            return;
        }

        changed = conn.update(imsCall, state);
        if (state == ImsPhoneCall.State.DISCONNECTED) {
            changed = conn.onDisconnect(cause) || changed;
@@ -949,7 +951,6 @@ public final class ImsPhoneCallTracker extends CallTracker {
            conn.getCall().detach(conn);
            removeConnection(conn);
        }
        }

        if (changed) {
            if (conn.getCall() == mHandoverCall) return;