RCONInstance: remove redundant size ref param from readPacket()

This commit is contained in:
Dylan K. Taylor 2018-05-07 13:53:34 +01:00
parent 0e5504ed3f
commit 24aab8365e

View File

@ -80,7 +80,7 @@ class RCONInstance extends Thread{
return socket_write($client, Binary::writeLInt(strlen($pk)) . $pk); return socket_write($client, Binary::writeLInt(strlen($pk)) . $pk);
} }
private function readPacket($client, &$size, &$requestID, &$packetType, &$payload){ private function readPacket($client, &$requestID, &$packetType, &$payload){
socket_set_nonblock($client); socket_set_nonblock($client);
$d = socket_read($client, 4); $d = socket_read($client, 4);
if($this->stop){ if($this->stop){
@ -142,7 +142,7 @@ class RCONInstance extends Thread{
$this->{"status" . $n} = self::STATUS_DISCONNECTED; $this->{"status" . $n} = self::STATUS_DISCONNECTED;
continue; continue;
} }
$p = $this->readPacket($client, $size, $requestID, $packetType, $payload); $p = $this->readPacket($client, $requestID, $packetType, $payload);
if($p === false){ if($p === false){
$this->{"status" . $n} = self::STATUS_DISCONNECTED; $this->{"status" . $n} = self::STATUS_DISCONNECTED;
continue; continue;