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

Commit 3380f496 authored by Ihab Awad's avatar Ihab Awad Committed by Android Git Automerger
Browse files

am 8ea0d19f: am 93b42924: Merge "Fix immutability bug in http://ag/587241" into lmp-mr1-dev

* commit '8ea0d19f':
  Fix immutability bug in http://ag/587241
parents 35bed6fd 8ea0d19f
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -1310,14 +1310,18 @@ public abstract class Connection implements IConferenceable {
    }

    private static class FailureSignalingConnection extends Connection {
        private boolean mImmutable = false;
        public FailureSignalingConnection(DisconnectCause disconnectCause) {
            setDisconnected(disconnectCause);
            mImmutable = true;
        }

        public void checkImmutable() {
            if (mImmutable) {
                throw new UnsupportedOperationException("Connection is immutable");
            }
        }
    }

    /**
     * Return a {@code Connection} which represents a failed connection attempt. The returned