Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Does request-download download all file into memory?

 [1/2] from: petr::krenzelok::trz::cz at: 6-Feb-2002 11:51


Hi, I just tried to download one large file from our intranet and was wondering, that "Not enough memory" message appeared in Rebol in console. Could anyone look at request-download ---> read-thru ----> read-net functions, as it seems to me that read-net function reads only part of the port, but it appends it to buffer, which is just rebol word, not opened file ... If so, then I don't understand why it is so, because if read-net/to is specified, we alredy know name of the file we can spool partialy downloaded data into. I sometimes miss such anync + memory safe behavior of default rebol functions. I know I can code it myself, but .... simplicity in default distro is always welcomed ;-) -pekr-

 [2/2] from: rotenca:telvia:it at: 6-Feb-2002 14:55


> I just tried to download one large file from our intranet and was > wondering, that "Not enough memory" message appeared in Rebol in
<<quoted lines omitted: 8>>
> of default rebol functions. I know I can code it myself, but .... > simplicity in default distro is always welcomed ;-)
Fro what i understand, read-net create a buffer of the exact lenght of http page if it can found it in the headers object, else use a 8000 byte buffer: size: to-integer any [port/locals/headers/content-length 8000] buffer: make binary! size --- Ciao Romano

Notes
  • Quoted lines have been omitted from some messages.
    View the message alone to see the lines that have been omitted