R. David Murray added the comment:

Ah, in fact that's exactly where it comes from, since httplib uses the email 
header parsing code.  In python3 we are actually using the email package to 
parse the headers (which is sensible) (in 2.7 it is a copy of code from the old 
mimelib with some tweaks).  Fixing this in python3 is best done by making the 
error recovery enhancement(s) I mentioned in the email package.  

Please note that changing this behavior has the potential to break working 
code.  That is, just as we have here a server that is out of spec and sending 
invalid links in the middle of headers, we may have a server that is out of 
spec by not sending the blank delimiter, which is currently being handled 
"correctly".  Thus I don't think your simple fix is advisable, instead I think 
we should pursue the more complicated "look ahead" fix.

----------
versions:  -Python 3.3

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24363>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to