Bugfix Json consumer logic
This commit is contained in:
@@ -91,6 +91,9 @@ class JsonProtocol implements ProtocolInterface
|
||||
{
|
||||
// check for $this->prependSizeBytes
|
||||
if ($this->prependSizeBytes > 0) {
|
||||
if (strlen($data) < $this->prependSizeBytes) {
|
||||
return null;
|
||||
}
|
||||
$len = $this->unpackSizeBytes($data);
|
||||
// if size is greater than data (i.e. incomplete)
|
||||
if ($len > strlen($data) - $this->prependSizeBytes) return null;
|
||||
|
||||
Reference in New Issue
Block a user