Fixes #657
@@ -5,6 +5,9 @@
* Don't write to stdout and stderr when they are not available
(such as is the case for pythonw). (Sylvia van Os, #652)
+ * Fix compatibility with newer versions of git, which expect CONTENT_LENGTH
+ to be set to 0 for empty body requests. (Jelmer Vernooij, #657)
+
0.19.6 2018-08-11
BUG FIXES
@@ -500,6 +500,7 @@ class GitHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
data = self.rfile.read(nbytes)
else:
data = None
+ env['CONTENT_LENGTH'] = '0'
# throw away additional data [see bug #427345]
while select.select([self.rfile._sock], [], [], 0)[0]:
if not self.rfile._sock.recv(1):