IETF-SSH archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
RE: Questions on reading a writing of text files....
> When operating in text mode, should a read just return one line (with the
> appropriate end of line sequence), or should it fill the buffer,
separating
> each line with the end of line sequence. What if a line has more
characters
> than are available in the buffer, should the portion that fits be returned
> and the remainder saved for the next read?
>
> There are fewer questions about writes, but what should be done with a
write
> that does not end in the end of line sequence? Should it wait for another
> write that contains the sequence and the two be appended?
Good questions. I was assuming the operating characteristics of read and
write would not change, which means partial lines could be both read and
written. This is definitely the simplest way to go in terms of the amount
of verbiage needed for the draft. (For example, line is too big for buffer
question just goes away.)
Is it too onerous to implement, do you think?
- Joseph
Partial reads are not difficult to implement.
Partial writes could be difficult to implement, depending upon VMS file
organization and whether or not the write is at the end of the file.
I think that a line stating "All end of line sequences are explicit when
operating on a file in text mode." would eliminate any confusion.
----------------------
Richard Whalen
Process Software
Home |
Main Index |
Thread Index |
Old Index