curl-and-php
Re: help with PUT and CURLOPT_READFUNCTION
Date: Thu, 1 May 2008 14:14:11 -0700 (PDT)
Can anyone who's familiar with the php binding confirm
that the file being PUT is streamed and not first
stored in memory? If so, it will help me pin down why
I can't put files over a certain size without running
out of memory...
Thanks Daniel.
>> I can successfully PUT a file using CURLOPT_PUT,
CURLOPT_INFILE, and
>> CURLOPT_INFILESIZE. However, for large files ( >
~100MB) my machine runs out
>> of memory so I want to be able to "stream" the file
to the webserver
>> (instead of storing it in memory and then sending)
via CURLOPT_READFUNCTION.
> I'm sorry, but I don't buy this explanation. libcurl
itself only supports HTTP
> PUT by streaming the upload, and I'm quite sure the
PHP layer doesn't add any
> major magic to that. Thus, the size of the PUT
upload has no relevance, it
> always takes roughly the same amount of memory!
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2008-05-01