Skip to content
Myr

Release redirected connections.

Before adoption: this commit came in with the history the project adopted, so no landing records it.

#239

authored by Kenneth Reitz · committed by Kenneth Reitz · parent e695941 · Browse files · 1 file+4 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−1 removed

  • other:+4 added−1 removed

1 file+4 added−1 removed

modified:requests/models.py+4 added-1 removed
214 unmodified lines
215216 if not len(history) < self.config.get('max_redirects'):217 raise TooManyRedirects()218219 # Release the connection back into the pool.220 r.raw.release_conn()221222 history.append(r)223224 url = r.headers['location']225
280 unmodified lines
506 cookie_header = c.output(header='', sep='; ').strip()507508 # Attach Cookie header to request.509 self.headers['Cookie'] = cookie_header507 510511 # Pre-request hook.512 r = dispatch_hook('pre_request', self.hooks, self)513 self.__dict__.update(r.__dict__)514
293 unmodified lines