Closing tcp connection #34
This commit is contained in:
parent
f50db37e12
commit
4952f02a7a
|
@ -171,15 +171,14 @@ class Misc
|
|||
{
|
||||
$handle = @fsockopen($host, $port, $errno, $errstr, $timeout);
|
||||
|
||||
if ($handle)
|
||||
if (!$handle)
|
||||
{
|
||||
fclose($handle);
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
fclose($handle);
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
elseif ($protocol == 'udp')
|
||||
|
|
Loading…
Reference in New Issue