Bug #13516 Updated: fpassthru uses too much memory
| From: | jimw@php.net | Date: | Sun, 10 Feb 2002 04:56:28 +0000 |
| Subject: | Bug #13516 Updated: fpassthru uses too much memory | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-34@lists.php.net to get a copy of this message | ||
ID: 13516
Updated by: jimw@php.net
Reported By: maardsma@arpinternational.com
-Status: Open
+Status: Closed
Bug Type: Feature/Change Request
Operating System: Irix
PHP Version: 4.0.6
New Comment:
fpassthru() uses mmap() or does pass the file in chunks. it doesn't
consume real memory.
Previous Comments:
------------------------------------------------------------------------
[2001-11-14 06:48:49] sander@php.net
Not a bug. Reclasified as a feature/change request.
------------------------------------------------------------------------
[2001-10-02 12:39:53] maardsma@arpinternational.com
When using fpassthru to output the contents of a large >1MB file it
uses a lot of memory which causes my ISP's web server to terminate the
httpd thread because it used too much memory. As a result the download
is cut off.
If I use fread to read the file 1K at a time it works ok.
Shouldn't fpassthru read a 1 or 10K chunks to avoid excess memory use
on large files?
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=13516&edit=1