From:             odarcan at hotmail dot com
Operating system: win xp
PHP version:      4.3.2
PHP Bug Type:     Network related
Bug description:  fread'ing with large buffers from slow pages does not work

Description:
------------
$pcstring=fread ($pcpointer,1000);
$pcstring.=fread ($pcpointer,1000);
$pcstring.=fread ($pcpointer,1000);
$pcstring.=fread ($pcpointer,1000);
$pcstring.=fread ($pcpointer,1000);

is NOT the same as

$string=fread ($pcpointer,5000);

at least not in slow opening pages (as php scripts doing calculations)

the second code only gives the headers while skipping the rest while the
first shows echoed results from the php script (as it did with previous
versions of php)

putting a sleep(1); before the fread also solves this (for me at least).

sleep(1);
$string=fread ($pcpointer,5000);


it has taken me 5 days to figure out what was wrong, FIVE DAYS...



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

Reply via email to