but that would have left nothing left to say.... I would generally read in 512 bytes anyway as this is a generally a sector and realistically the smallest chunk of a disk that the OS ever reads. This was an example and the limitation is self evident I would have thought. As it happens it will only take of the last 10 'newline' CRLF line endings on Windows if we want to get really picky ;-)
If you want to move on to the more arcane and esoteric neither seek() nor read() for that matter can be relied upon to do exactly what you ask. From the docs....
If you want to position file for sysread or syswrite, don't use seek--
+buffering makes its effect on the file's system position unpredictabl
+e and non-portable. Use sysseek instead.
cheers
tachyon
s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print
|