Steaming PDF from Python Script to IE

JanC usenet_spam at janc.invalid
Sun Jun 22 01:16:41 EDT 2003


Stephen Thorne <stephen at thorne.id.au> schreef:

> Also windows likes \r\n for CRLF, whereas you were just sending LF
> (which is sufficient for unixes). 

This has nothing to do with Windows vs. unix, the HTTP standard defines 
CRLF as the only valid EOL marker for everything except the body.


>From RFC-2616 "Hypertext Transfer Protocol -- HTTP/1.1":

| 2.2 Basic Rules
| 
| [...]
|    HTTP/1.1 defines the sequence CR LF as the end-of-line marker for all
|    protocol elements except the entity-body (see appendix 19.3 for
|    tolerant applications). The end-of-line marker within an entity-body
|    is defined by its associated media type, as described in section 3.7.

Appendix 19.3 recommends tolerance for broken applications that send only 
LF as EOF-marker.

-- 
JanC

"Be strict when sending and tolerant when receiving."
RFC 1958 - Architectural Principles of the Internet - section 3.9




More information about the Python-list mailing list