From: gzaboy at hotmai dot com
Operating system: windows 2003 server
PHP version: 5.1.4
PHP Bug Type: *Network Functions
Bug description: timeout option of fsockopen seems to be ignored
Description:
------------
the timeout option of fsockopen seems to be ignored below code,if remote
host has no responed,the error information:"Error" would not display:
Reproduce code:
---------------
$h = fsockopen($server,80,$errno,$errstr,5);
if($h){
fwrite($h,$post);
while(!feof($h)){
$str .= fgets($h,127);
}
fclose($h);
return $str;
}else{
die("Error");
}
Expected result:
----------------
die("Error");
--
Edit bug report at http://bugs.php.net/?id=37517&edit=1
--
Try a CVS snapshot (PHP 4.4):
http://bugs.php.net/fix.php?id=37517&r=trysnapshot44
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=37517&r=trysnapshot52
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=37517&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=37517&r=fixedcvs
Fixed in release:
http://bugs.php.net/fix.php?id=37517&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=37517&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=37517&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=37517&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=37517&r=support
Expected behavior: http://bugs.php.net/fix.php?id=37517&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=37517&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=37517&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=37517&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37517&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=37517&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=37517&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=37517&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=37517&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=37517&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=37517&r=mysqlcfg