in reply to Opening a file at a designated offset based on closing of the file

Probably the best way is to keep track of the number of bytes you read in, then save that value to a file. Upon the next run, you can read that value back and then use seek to go there.

Alternatively, you could use my $size = -s "filename"; when you're done, though it's a potential race condition (if something adds to the file after you call the above).

Update: Never mind. Forgot about tell.

----
I wanted to explore how Perl's closures can be manipulated, and ended up creating an object system by accident.
-- Schemer

: () { :|:& };:

Note: All code is untested, unless otherwise stated