Skip to content

Commit 4990e05

Browse files
committed
+4 (fix an extremely rare bug with packet splitting)
the client would hard-crash if packet size was exactly more than i + packSize, but less than i + 4 + packSize (4 being the packet size bits)
1 parent 9786a12 commit 4990e05

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Client/objects/oClient/Other_68.gml

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ switch(type) {
5757
var packSize = buffer_peek(buff, i, buffer_u32);
5858

5959
// if exceding the packet size
60-
if (i + packSize > size) {
60+
if (i + 4 + packSize > size) {
6161
halfpack = buffer_create(size-i, buffer_fixed, 1);
6262
buffer_copy(buff, i, size-i, halfpack, 0);
6363
//trace("half in-")

0 commit comments

Comments
 (0)