Failsafe stream_select

Fixes #9
This commit is contained in:
Pedro Cardoso da Silva 2021-06-29 16:27:40 -03:00 committed by GitHub
parent 2139eeae07
commit 24fff22f9b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -194,7 +194,7 @@ class WhoisClient {
while (!feof($ptr))
{
if (stream_select($r,$null,$null,$this->STIMEOUT))
if (@stream_select($r,$null,$null,$this->STIMEOUT)!==false)
{
$raw .= fgets($ptr, $this->BUFFER);
}