[racket-dev] random-access file reading

From: Andreas Rottmann (a.rottmann at gmx.at)
Date: Tue Sep 28 18:04:20 EDT 2010

John Clements <clements at brinckerhoff.org> writes:

> I want to read a chunk from the middle of a 50-megabyte file.  As far
> as I can see, there are no random-access file primitives currently in
> DrRacket.  Also, I don't see a "skip-bytes", so it looks like I should
> be allocating a junk buffer and then repeatedly calling read-bytes to
> read the skipped portion into the junk buffer.
> Tell me if there's a simpler way to do this; doc pointers always appreciated.

I think this should do the job.

Cheers, Rotty
Andreas Rottmann -- <http://rotty.yi.org/>

Posted on the dev mailing list.