ID:               49706
 Comment by:       tantaoui at gmail dot com
 Reported By:      alex at innovacomputing dot com
 Status:           Open
 Bug Type:         Streams related
 Operating System: Debian 5.0.3/amd64
 PHP Version:      5.2.11
 New Comment:

It works correctly for me in 5.2.10 but not in 5.2.11 under Windows
Server 2003. it seems to be OK in 5.2.12 (snapshot)


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

[2009-09-29 06:20:08] alex at innovacomputing dot com

Description:
------------
feof() seems to have broken on socket streams somewhere between version
5.2.9 and 5.2.11.

When running the code included in this bug report on PHP 5.2.9, it
returns "bool(false)", which is the correct behavior.  However, when
upgrading to PHP 5.2.11, feof() will incorrectly return "bool(true)".

Note that I've only been able to reproduce this on a 64-bit server. 
PHP 5.2.11 on the 32-bit server that I've also tested with correctly
returns "bool(false)".

Reproduce code:
---------------
<?php
list($a, $b) = stream_socket_pair(STREAM_PF_UNIX, STREAM_SOCK_STREAM,
STREAM_IPPROTO_IP);
fwrite($a, 'Test');
var_dump(feof($b));


Expected result:
----------------
bool(false)

Actual result:
--------------
bool(true)


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


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

Reply via email to