改名
This commit is contained in:
+13
-9
@@ -248,15 +248,19 @@ class Socket
|
|||||||
|
|
||||||
$this->readWatcher = \Amp\onReadable($this->stream, function () {
|
$this->readWatcher = \Amp\onReadable($this->stream, function () {
|
||||||
do {
|
do {
|
||||||
if(!$this->isSocketDead($this->stream)){
|
try {
|
||||||
$newData = @fread($this->stream, self::READ_MAX_LEN);
|
if(!$this->isSocketDead($this->stream)){
|
||||||
}else{
|
$newData = @fread($this->stream, self::READ_MAX_LEN);
|
||||||
$this->reconnect();
|
}else{
|
||||||
return;
|
$this->reconnect();
|
||||||
}
|
return;
|
||||||
if ($newData) {
|
}
|
||||||
$this->read($newData);
|
if ($newData) {
|
||||||
}
|
$this->read($newData);
|
||||||
|
}
|
||||||
|
}catch (\Exception $exception){
|
||||||
|
var_dump($exception->getMessage());
|
||||||
|
}
|
||||||
} while ($newData);
|
} while ($newData);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user