On 04/30/2012 07:37 PM, Paul Reinheimer wrote:
Hi Larry,

4) So given #2 and #3, the "readfile() will kill your memory, don't use it"
line is a persistent urban legend that belongs on Snopes as debunked.
  Looping on fread() for performance is a red herring.
I implemented this earlier this very year to avoid memory issues (a
quick look at project history shows me working on it in January). The
difference between using readfile, and some convoluted method from the
documentation comments was clear and immediate: corrupted download
with out of memory error in the logs, to things working just fine.

Let me re-create with a simple test script and share my server details
before we call snopes :)

Fascinating. I even verified the md5sum of the file I got on the other end just to be sure. I'll hold off on the blog post then. :-) I look forward to your test setup.

--Larry Garfield

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to