Don't hang if socket fails to open
feof($f) returns false if $f is invalid, so if the socket failed to open we spun forever, causing the tests to eventually timeout. The test will still fail, but at least we get meaningful results for the rest.
Esse commit está contido em:
@@ -52,7 +52,7 @@ fwrite($f,
|
||||
"Connection: Close\r\n".
|
||||
"\r\n");
|
||||
$response = '';
|
||||
while (!feof($f)) {
|
||||
while ($f && !feof($f)) {
|
||||
$line = fgets($f, 128);
|
||||
$response .= $line;
|
||||
}
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário