Attempt to fix additional EOF problem
This commit is contained in:
Timothy Bish 2015-04-02 09:09:06 -04:00
parent a6243225c5
commit 299410820e
2 changed files with 6 additions and 6 deletions

View File

@ -76,12 +76,12 @@ class StompSocket extends TransportSupport implements WebSocket.OnTextMessage, S
try {
if (data != null) {
if (data.startsWith("\n")) {
if (data.equals("\n")) {
sendToActiveMQ(new KeepAliveInfo());
}
} else {
protocolConverter.onStompCommand((StompFrame)wireFormat.unmarshal(new ByteSequence(data.getBytes("UTF-8"))));
}
}
} catch (Exception e) {
onException(IOExceptionSupport.create(e));
}

View File

@ -136,12 +136,12 @@ class StompSocket extends TransportSupport implements WebSocketListener, StompTr
try {
if (data != null) {
if (data.startsWith("\n")) {
if (data.equals("\n")) {
sendToActiveMQ(new KeepAliveInfo());
}
} else {
protocolConverter.onStompCommand((StompFrame)wireFormat.unmarshal(new ByteSequence(data.getBytes("UTF-8"))));
}
}
} catch (Exception e) {
onException(IOExceptionSupport.create(e));
}