Adrianna Pinska <[EMAIL PROTECTED]> added the comment:

Ordinarily, request.get_selector() returns the portion of the url after
the host, and sel_host is None.  However, if a proxy is set on the
request, the request's host is set to the proxy host, get_selector()
returns the original full url, and sel_host is the host from the
original url (and different to the host set on the request).

This bug is only triggered if the double slash comes directly after the
host and there is no proxy set on the request.  do_request_ does not
check what get_selector() is returning, so the output is passed through
splithost even when this is not necessary, and in this particular case
it causes undesirable behaviour.

My patch causes do_request_ only to attempt to extract the host from
get_selector() if the proxy has been set.

----------
keywords: +patch
nosy: +confluence
Added file: http://bugs.python.org/file10255/double_slash_after_host.patch

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2776>
__________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to