Bug #53380 [Fbk->NoF]: fgets() hangs on repetitive connection to same url

From: Date: Mon, 18 Feb 2013 00:34:36 +0000
Subject: Bug #53380 [Fbk->NoF]: fgets() hangs on repetitive connection to same url
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-176938@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=53380&edit=1

 ID:               53380
 Updated by:       php-bugs@lists.php.net
 Reported by:      kontakt at beberlei dot de
 Summary:          fgets() hangs on repetitive connection to same url
-Status:           Feedback
+Status:           No Feedback
 Type:             Bug
 Package:          Sockets related
 Operating System: Ubuntu 10.10
 PHP Version:      5.3.3

 New Comment:

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


Previous Comments:
------------------------------------------------------------------------
[2010-11-23 04:39:28] cataphract@php.net

I can't find anything wrong here.

The request is apparently successfully written (fwrite in PHP and the send() syscall return
immediately, indicating it was put in the send buffer of the socket).

Then, the script calls fgets, which tries to read from the socket. However, this operation times
out. Likely, the server was not able to respond in such a short period of time (1 second). I suggest
you increase the timeout and try again.

------------------------------------------------------------------------
[2010-11-22 19:39:35] kontakt at beberlei dot de

Description:
------------
I stumbled into this bug where fgets() hangs on me as long as the connection timeout with a http
socket resource (CouchDB webserver).

The reproduce code is a bit longish as i think it has to do with the fetching of the same url twice.
It makes no difference though if i use Keep Alive or close Connections after usage.

Code: http://pastie.org/1317962
Xdebug Output: http://pastie.org/1317997

Strace output is attached.



------------------------------------------------------------------------



-- 
Edit this bug report at https://bugs.php.net/bug.php?id=53380&edit=1


Thread (3 messages)

« previous php.bugs (#176938) next »