Author jimr
Recipients demian.brecht, jimr, martin.panter
Date 2015-02-27.22:09:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1425074999.52.0.0168811265087.issue23539@psf.upfronthosting.co.za>
In-reply-to
Content
The first patch should actually be modified so the condition reads (update attached):

    if body is None and method_expects_body:
        thelen = 0
    elif body is not None:
        ...

Demian, I believe this is equivalent to your 'expecting_len' proposal, I've just put the logic inside _set_content_length. My approach was to leave as much existing logic as possible in place to avoid the introduction of new bugs (first patch wasn't entirely successful in this!).

As for OPTION, 

   If the OPTIONS request includes a message-body (as indicated by the
   presence of Content-Length or Transfer-Encoding), then the media type
   MUST be indicated by a Content-Type field.  Although this
   specification does not define any use for such a body, future
   extensions to HTTP might use the OPTIONS body to make more detailed
   queries on the server.

From http://tools.ietf.org/html/draft-ietf-httpbis-p2-semantics-14#section-7.2
History
Date User Action Args
2015-02-27 22:09:59jimrsetrecipients: + jimr, martin.panter, demian.brecht
2015-02-27 22:09:59jimrsetmessageid: <1425074999.52.0.0168811265087.issue23539@psf.upfronthosting.co.za>
2015-02-27 22:09:59jimrlinkissue23539 messages
2015-02-27 22:09:59jimrcreate