Details
-
Bug
-
Resolution: Done
-
Major
-
1.0.0.Final
-
None
Description
In method handleEvent of class BufferedTextMessage, at line 104 there is the code fragment:
if (res == -1) { checkMaxSize(channel, res); buffer.flip(); data.write(buffer); complete = true; callback.complete(channel.getWebSocketChannel(), BufferedTextMessage.this); return; }
Now the first thing "checkMaxSize" does is to add "res" to "currentSize", in this case decreasing it by one, which seems to be incorrect behavior.
In fact we detected this problem when we were trying to find the cause of a strange websocket-related problem. After commenting out the call to "checkMaxSize", our application worked correctly.