Bug #15091: socket_set_timeout not part of windows binary
| From: | Rajkumar dot Bellan at saint-gobain dot com | Date: | Thu, 17 Jan 2002 23:28:21 +0000 |
| Subject: | Bug #15091: socket_set_timeout not part of windows binary | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-77375@lists.php.net to get a copy of this message | ||
From: Rajkumar.Bellan@saint-gobain.com
Operating system: windows 2000
PHP version: 4.1.1
PHP Bug Type: Sockets related
Bug description: socket_set_timeout not part of windows binary
I am using windows binaries.
$fp = $fsockopen(($ip_addr, $port_no, $errno, $errstr, 30);
do {
if (!feof($fp)) {
$livedata = trim(fgets($fp,128));
echo $livedata."\n";
}
else {
break;
}
} while(true);
when there is no data being sent by the server my script waits
indefinitely at fgets. I tried using socket_set_blocking($fp, false) but
that does get me data every one second. I tried to use socket_set_timeout
that is when I found out it is not supported in windows binaries. Is there
any other way to solve this problem in windows.
--
Edit bug report at: http://bugs.php.net/?id=15091&edit=1