HP3000-L Archives

February 1997, Week 4

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Bruce Toback <[log in to unmask]>
Reply To:
Bruce Toback <[log in to unmask]>
Date:
Mon, 24 Feb 1997 13:05:10 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (44 lines)
Gavin writes:

>So now we have the ability to use this [line termination flag] information
>(optionally) when
>reading the file.  Since we haven't tried to translate the file contents
>in any way, we haven't had an opportunity to corrupt the file as would
>be the case if the server tried to "intelligently" translate ASCII files
>to LF format when stored on the 3000, and back to the appropriate format
>when serving the file up to a non-LF type client.  The worst thing that
>will happen is that if we want to serve a file to a client that uses a
>different line terminator than the client that created the file, we
>might inappropriately perform a conversion on the file when serving it.
>In this case you would have to take some action to force the transfer
>to disable the translation, but at least the data would then be available
>in an uncorrupted state.

While the flag is unquestionably useful for MPE programs trying to read a
file, it's of much less value for server programs. A server program that
tries to do EOL translation for its clients risks corrupting data for
non-text files. And unlike the POSIX library, which at least gets the
fopen() parameters, the server has no way of knowing whether a client
intends to treat the file as text or binary.

Again, though, the flag would be very useful for MPE programs that
process or create files intended to be accessed via file server programs,
especially if the file system or POSIX library takes care of all the
translation.

>Comments?

Comments, unless embedded within text and enclosed within
language-dependent comment delimiters, should be terminated with whatever
line termination scheme the file uses.

-- Bruce


--------------------------------------------------------------------------
Bruce Toback    Tel: (602) 996-8601| My candle burns at both ends;
OPT, Inc.            (800) 858-4507| It will not last the night;
11801 N. Tatum Blvd. Ste. 142      | But ah, my foes, and oh, my friends -
Phoenix AZ 85028                   | It gives a lovely light.
[log in to unmask]                   |     -- Edna St. Vincent Millay

ATOM RSS1 RSS2