Fix control event String parsing
At least 2 bytes must be available to read the length of the String.
This commit is contained in:
@@ -93,7 +93,7 @@ public class ControlEventReader {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private ControlEvent parseTextControlEvent() {
|
private ControlEvent parseTextControlEvent() {
|
||||||
if (buffer.remaining() < 1) {
|
if (buffer.remaining() < 2) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
int len = toUnsigned(buffer.getShort());
|
int len = toUnsigned(buffer.getShort());
|
||||||
|
|||||||
Reference in New Issue
Block a user