#21656 [Opn->Fbk]: fclose() don't close the socket

From: Date: Wed, 15 Jan 2003 14:02:46 +0000
Subject: #21656 [Opn->Fbk]: fclose() don't close the socket
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-30112@lists.php.net to get a copy of this message
 ID:               21656
 Updated by:       wez@php.net
 Reported By:      azevedo@tchelinux.com.br
-Status:           Open
+Status:           Feedback
 Bug Type:         Sockets related
 Operating System: Linux (Slackware)
 PHP Version:      4.3.0
 New Comment:

Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.





Previous Comments:
------------------------------------------------------------------------

[2003-01-15 07:31:58] azevedo@tchelinux.com.br

Hi,

I've made a script to connect using fsockopen() (not pfsockopen()), and
check the timeout into while. If the connection got a time out, I close
the socket and restart the request again.
The problem is that when I got some network problem that made the
connection to be lost, the PHP script simple doesn't close this socket
with fclose() and when I open the socket again, I can't send or receive
any data.
The script is running at shell, and is fetching many web pages to
insert into a mysql database.
All works fine, till I got any network problem.

I've searched all the documentation and bug reports and there's nothing
talking about the fclose() to not real close the socket.

There's any other way to really force the socket to be closed and
oppened again in the same script?

Thanks in advice.

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


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



Thread (7 messages)

« previous php.bugs (#30112) next »