#35859 [Csd]: fread limited to 8K

From: Date: Sun, 26 Feb 2006 18:00:29 +0000
Subject: #35859 [Csd]: fread limited to 8K
References: 1  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969372120@lists.php.net to get a copy of this message
ID: 35859 User updated by: cpuidle at gmx dot de Reported By: cpuidle at gmx dot de Status: Closed Bug Type: Documentation problem Operating System: WinXP SP2 PHP Version: 5.1.1 New Comment: Now to summarize what happened: 1) For local files, PHP behaved exactly like documented until version 5.1.0 2) When 5.1.1 was introduced, local file behaviour for fread() changed to limit to 8K blocks- however if and only if a user stream was opened before 3) In response to this, the documentation was changed to accomodate for the user stream behaviour. What I'm asking the PHP developers community to ask them selves very seriously is this: a) won't this break compatibility with many existing software as PHP5 becomes more widely spread (Smarty etc)? b) isn't the bahviour change of fread depending on other criteria itself a strangeness? and c) looking at this issue- is PHP in any way enterprise-ready? Sincerely, Andreas Goetz Previous Comments: ------------------------------------------------------------------------ [2006-01-30 16:48:55] vrana@php.net This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. "(for userspace streams)" changed to "(after opening userspace stream)". ------------------------------------------------------------------------ [2006-01-16 09:19:33] cpuidle at gmx dot de Sorry, but the documentation is still wrong- did anybody ever look at the code to reproduce?! "or (for userspace streams) when 8192 bytes have been read whichever comes first." When stream wrappers are not used (even unrelated protocols count as stream wrapper use), the 8K limit is not in effect. So- documentation wrong again... ------------------------------------------------------------------------ [2006-01-13 12:00:42] vrana@php.net This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. "Reading stops when up to length bytes have been read, EOF (end of file) is reached, (for network streams) when a packet becomes available, or (for userspace streams) when 8192 bytes have been read whichever comes first." ------------------------------------------------------------------------ [2006-01-06 16:55:51] cpuidle at gmx dot de OK, at least a documentation problem, thanks. The dependency on stread wrappers still seem to be a non-docs bug to me. And the sudden change in behaviour certainly doesn't help with the often-claimed enterprise readiness... Why should existing 5.0.5 code suddenly break with 5.1.1? ------------------------------------------------------------------------ [2006-01-06 16:50:09] sniper@php.net reclassified (see bug #30936 for Wez's comment) ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/35859 -- Edit this bug report at http://bugs.php.net/?id=35859&edit=1

« previous php.doc (#969372120) next »