From be62645dd56580dd7576032b348cf79d880851d8 Mon Sep 17 00:00:00 2001 From: Ian Cordasco Date: Mon, 25 Feb 2013 09:29:05 -0500 Subject: [PATCH] Revert "If Content-Length is already set.."[1] This reverts commit 544d08d0f61c35358cf13b4a6b677e4e51dbbe7e. [1]"If Content-Length is already set, don't over ride it" --- requests/models.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/requests/models.py b/requests/models.py index fe85a83..898ed66 100644 --- a/requests/models.py +++ b/requests/models.py @@ -386,8 +386,6 @@ class PreparedRequest(RequestEncodingMixin, RequestHooksMixin): self.body = body def prepare_content_length(self, body): - if self.headers.get('Content-Length'): - return if hasattr(body, 'seek') and hasattr(body, 'tell'): body.seek(0, 2) self.headers['Content-Length'] = str(body.tell()) -- 2.7.4