Hacker News new | ask | show | jobs
by throw10920 764 days ago
Thank you for weighing in, John Nagle!

I understand that constraint, and it seems reasonable - but in that case, why not use a length prefix? That should be even more efficient than having to scan for a line containing a single period and nothing else.

1 comments

Because many paths of that era were not binary-transparent. There was CR-LF to LF conversion, the possibility of ASCII/EBCDIC translation, and other transformations.

Hence such horrors as MIME delimiters:

    -----=_Part_2827761_1947716067.1716352583971
    Content-Type: multipart/alternative; 
    boundary="----=_Part_2827760_1372041171.1716352583736"
We still have the mess that is the required and standardized behavior of HTML5 parsers faced with bad data.
That's genuinely horrifying, but it explains why SMTP made a decision that I would otherwise categorize as "insane" - it was forced to by constraints of the time. Thank you for explaining!