summaryrefslogtreecommitdiff
path: root/Lib/httplib.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/httplib.py')
-rw-r--r--Lib/httplib.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/httplib.py b/Lib/httplib.py
index 5d16e53c4c..98296dc3c5 100644
--- a/Lib/httplib.py
+++ b/Lib/httplib.py
@@ -989,7 +989,7 @@ class HTTPConnection:
self.putrequest(method, url, **skips)
- if body and ('content-length' not in header_names):
+ if body is not None and 'content-length' not in header_names:
self._set_content_length(body)
for hdr, value in headers.iteritems():
self.putheader(hdr, value)