After a heated discussion with our host provider the connection is no longer closing.
But while we are here can anybody explain how a socket can return 'EOF'
I know a socket and a file are basically the same, but where does 'eof' come from.
TA
email socket closing
Collapse
X
-
email socket closing
A class I use (phpmailer) succesfully opens a mail socket.
[PHP]fsockopen(xxxx. XXXXXXXXXX.co.u k,25,$errno,$er rmsg,10)[/PHP]
immediately afterwards if I check the socketCode:Succesfully connected to fsockopen with smtp_conn Resource id #18 host of the server xxxx.XXXXXXXXXX.co.uk the port to use 25 error number if any 0 error message if any return value 10
[PHP]$sock_status = socket_get_stat us($this->smtp_conn);
print_r($sock_s tatus);[/PHP]I get the following
My question is does the 'EOF' and '0 unread bytes' mean the connection has closedCode:sock_status Array ( [stream_type] => tcp_socket [mode] => r+ [unread_bytes] => 0 [seekable] => [timed_out] => [blocked] => 1 [eof] => 1 )
because the writer of the class thinks so.
The email has worked fine for two years but started to fail yesterday
because the 'EOF' is returning '1'
I have no idea what was being returned before because I have just used this class blindly with great success.
Anybody know what is happening?Tags: None
Leave a comment: