am 93b42924: Merge "Fix immutability bug in http://ag/587241" into lmp-mr1-dev
* commit '93b429247673bb8e019fe9d39b46700fc86c3313': Fix immutability bug in http://ag/587241
This commit is contained in:
@@ -1310,14 +1310,18 @@ public abstract class Connection implements IConferenceable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private static class FailureSignalingConnection extends Connection {
|
private static class FailureSignalingConnection extends Connection {
|
||||||
|
private boolean mImmutable = false;
|
||||||
public FailureSignalingConnection(DisconnectCause disconnectCause) {
|
public FailureSignalingConnection(DisconnectCause disconnectCause) {
|
||||||
setDisconnected(disconnectCause);
|
setDisconnected(disconnectCause);
|
||||||
|
mImmutable = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void checkImmutable() {
|
public void checkImmutable() {
|
||||||
|
if (mImmutable) {
|
||||||
throw new UnsupportedOperationException("Connection is immutable");
|
throw new UnsupportedOperationException("Connection is immutable");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return a {@code Connection} which represents a failed connection attempt. The returned
|
* Return a {@code Connection} which represents a failed connection attempt. The returned
|
||||||
|
|||||||
Reference in New Issue
Block a user