Skip to content

Commit

Permalink
[project @ Remove range headers from requests]
Browse files Browse the repository at this point in the history
  • Loading branch information
tailor committed Oct 31, 2008
1 parent f2852a4 commit 17dd731
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions openid/fetchers.py
Expand Up @@ -198,9 +198,6 @@ def fetch(self, url, body=None, headers=None):
headers.setdefault(
'User-Agent',
"%s Python-urllib/%s" % (USER_AGENT, urllib2.__version__,))
headers.setdefault(
'Range',
'0-%s' % (1024*MAX_RESPONSE_KB,))

req = urllib2.Request(url, data=body, headers=headers)
try:
Expand Down Expand Up @@ -324,7 +321,6 @@ def write_data(chunk):
c.setopt(pycurl.HEADERFUNCTION, response_header_data.write)
c.setopt(pycurl.TIMEOUT, off)
c.setopt(pycurl.URL, openid.urinorm.urinorm(url))
c.setopt(pycurl.RANGE, '0-%s'%(MAX_RESPONSE_KB*1024))

c.perform()

Expand Down Expand Up @@ -394,9 +390,6 @@ def fetch(self, url, body=None, headers=None):

if headers is None:
headers = {}
headers.setdefault(
'Range',
'0-%s' % (1024*MAX_RESPONSE_KB,))

# httplib2 doesn't check to make sure that the URL's scheme is
# 'http' so we do it here.
Expand Down

0 comments on commit 17dd731

Please sign in to comment.