[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RFC1154 line counts again



Mark,

On UN*X, there is a particularily simple definition of
a line, in the context of SMTP and RFC822; sendmail (or
whatever, e.g. MMDF) have delivered the message into a file.

fgets(buf, 1000, file);

reads exactly one line. (for a little extra robustness, I use
1002, to deal with people who don't understand that 1000 *includes*
the CR LF terminator; but that doesn't matter here :-)

In practice, the line terminator in SMTP has to be seen
as either LF or CR LF if you want to talk to lots of existing
"implementations". I'm not sure this is a bad thing.

Rob