[REBOL] Re: Might as well ask..
From: gscottjones:mchsi at: 3-Oct-2002 14:38
Hi, Andy,
From: "Andy Finkel"
> Since the skip bug was known to the list, perhaps
> someone on the list has done the entire problem ,
> so I might as well ask :-)
I clearly am suffering from flatulence of the brain. After sending my last
submission stemming from Petr, I recalled doing something with Petr *last*
year along these lines, that time using *skip* but on a http network
connection. Here was the snippet (still works):
from-port: open/direct http://www.microsoft.com
to-port: open/direct %//windows/desktop/log.txt
from-port: skip from-port 8000 ;skip first 8000 bytes
;get 1000 byte chunks from file
while [data: copy/part from-port 1000][append to-port data]
close from-port
close to-port
Here was the email:
http://www.escribe.com/internet/rebol/m10053.html
> Has anyone done a tcp binary file transfer in rebol ?
> (one system sends, the other receives, both using the
> direct tcp: ports). FTP won't do it, as I need to process
> the file in 32K chunks (and I'd like to avoid the overhead
> of the ftp server). It's simple enough in C, but I thought I'd
> be able to more easily play around with different protocols
> if it were all in Rebol.
Shouldn't be too hard (he says with a great deal of bravado), but I have not
had the need to do this, per se. If the previously mentioned solutions
don't serve your needs (like you *really* need tcp, and want to avoid http)
and no one offers a solution, I could probably whip one up. I'm out of time
right now, but if no sno answers come forward, I'll check into it later
today.
--Scott Jones