Fix total number of bytes in sanity check
This commit is contained in:
parent
a7e448f6b4
commit
a7c1daf806
3 changed files with 4 additions and 4 deletions
|
@ -1,3 +1,3 @@
|
||||||
class Constants {
|
class Constants {
|
||||||
static const VERSION = "1.2.082924+1124";
|
static const VERSION = "1.2.082924+1447";
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@ class PacketServer {
|
||||||
var oldPos = layer.currentPosition;
|
var oldPos = layer.currentPosition;
|
||||||
layer.resetPosition();
|
layer.resetPosition();
|
||||||
int pktTotalExpected = layer.readLong();
|
int pktTotalExpected = layer.readLong();
|
||||||
if (pktTotalExpected <= layer.length) {
|
if (pktTotalExpected + 8 <= layer.length) {
|
||||||
// Allow Processing
|
// Allow Processing
|
||||||
} else {
|
} else {
|
||||||
layer.restorePosition(oldPos);
|
layer.restorePosition(oldPos);
|
||||||
|
@ -184,7 +184,7 @@ class PacketClient {
|
||||||
var oldPos = reply.currentPosition;
|
var oldPos = reply.currentPosition;
|
||||||
reply.resetPosition();
|
reply.resetPosition();
|
||||||
int lenOfReply = reply.readLong();
|
int lenOfReply = reply.readLong();
|
||||||
if (lenOfReply <= reply.length) {
|
if (lenOfReply + 8 <= reply.length) {
|
||||||
// We can now process the data
|
// We can now process the data
|
||||||
} else {
|
} else {
|
||||||
reply.restorePosition(oldPos);
|
reply.restorePosition(oldPos);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
name: libac_dart
|
name: libac_dart
|
||||||
description: "Aria's Creations code library"
|
description: "Aria's Creations code library"
|
||||||
version: 1.2.082924+1124
|
version: 1.2.082924+1447
|
||||||
homepage: "https://zontreck.com"
|
homepage: "https://zontreck.com"
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue