mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Use feof() in while loop
This commit is contained in:
parent
3995c70046
commit
7704efdb28
1 changed files with 2 additions and 2 deletions
|
@ -177,9 +177,9 @@ class CakeSocket {
|
|||
$req[] = 'Host: ' . $this->config['host'];
|
||||
$req[] = 'User-Agent: php proxy';
|
||||
|
||||
fwrite($this->connection, implode("\r\n", $req)."\r\n\r\n");
|
||||
fwrite($this->connection, implode("\r\n", $req) . "\r\n\r\n");
|
||||
|
||||
while(true) {
|
||||
while (!feof($this->connection)) {
|
||||
$s = rtrim(fgets($this->connection, 4096));
|
||||
if (preg_match('/^$/', $s)) {
|
||||
break;
|
||||
|
|
Loading…
Add table
Reference in a new issue