Allow getChannelInfo when in RETRIEVING_DATA state

This commit is contained in:
Manevolent
2018-10-23 09:52:46 -04:00
parent f06634879b
commit 3987f3c097
@@ -455,8 +455,10 @@ public class LocalTeamspeakClientSocket
final ClientCommandResponse<Iterable<T>> response; final ClientCommandResponse<Iterable<T>> response;
synchronized (commandSendLock) { synchronized (commandSendLock) {
if (getState() != ClientConnectionState.CONNECTED) if (getState() == ClientConnectionState.DISCONNECTED)
throw new IOException("not connected"); throw new IOException("not connected");
else if (getState() == ClientConnectionState.CONNECTING)
throw new IOException("connecting");
int maxReturnCode = calculateAcceptingReturnCode(); int maxReturnCode = calculateAcceptingReturnCode();
if (maxReturnCode == Integer.MAX_VALUE) maxReturnCode = 0; if (maxReturnCode == Integer.MAX_VALUE) maxReturnCode = 0;