From ad7316e87cd0444908caa74a5dfd4cf6168c5472 Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Sat, 1 Dec 2018 04:22:07 +0100 Subject: hgwebfs: write headers individually, so they are not limited by webfs iounit (thanks mischief) --- sys/lib/python/hgext/hgwebfs.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'sys/lib/python') diff --git a/sys/lib/python/hgext/hgwebfs.py b/sys/lib/python/hgext/hgwebfs.py index 45abf8cb5..9ae26b959 100644 --- a/sys/lib/python/hgext/hgwebfs.py +++ b/sys/lib/python/hgext/hgwebfs.py @@ -39,10 +39,12 @@ class Webconn: ctl.seek(0) ctl.write('url '+self.url) m = 'User-Agent: mercurial/proto-1.0\r\n'; - for h in req.headers: - m += h+': '+req.headers[h]+'\r\n' ctl.seek(0) ctl.write('headers '+m) + for h in req.headers: + ctl.seek(0) + ctl.write('headers '+h+': '+req.headers[h]+'\r\n') + if req.has_data(): data = req.get_data() post = open(self.dir+'/postbody', 'w', 0); -- cgit v1.2.3