From:             tomato at pisem dot net
Operating system: FreeBSD-4.7-Stable
PHP version:      4.3.2
PHP Bug Type:     Sockets related
Bug description:  problem with timeout parameter for fsockopen() function

Description:
------------
I'm trying to do socket connection with group of servers and for the
server's that did not work function fsockopen() runs around 300-500 sec
even the timeout is 10 sec.
i heard the problem was that this timeout used only in connect function,
but not in gethostbyname
i read that you fixed this problem long time ago.. but my version is PHP
4.3.2RC4 (cli) (built: Jun 19 2003 14:41:09)
and the problem is still exists



 

Reproduce code:
---------------
$fp = fsockopen($href,$port,$errno,$errstr,10);


Expected result:
----------------
connect or failed to connect after 10 seconds or less

Actual result:
--------------
Warning: fsockopen(): php_network_getaddresses: getaddrinfo failed: No
address associated with hostname in /.../script.php

-- 
Edit bug report at http://bugs.php.net/?id=24867&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=24867&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=24867&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=24867&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=24867&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=24867&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=24867&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=24867&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=24867&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=24867&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=24867&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=24867&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24867&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=24867&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=24867&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=24867&r=gnused

Reply via email to