From: Ian Jackson Date: Wed, 22 Mar 2017 23:35:04 +0000 (+0000) Subject: wip X-Git-Tag: hippotat/1.0.0~55^2~209 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ian/git?a=commitdiff_plain;h=3dbadade0fa7039ef22c656d54729bdf81c956d9;p=hippotat.git wip --- diff --git a/client b/client index 39e04c5..48b635a 100755 --- a/client +++ b/client @@ -51,13 +51,14 @@ def outbound(packet, saddr, daddr): queue.append(packet) check_outbound() -def req_ok(data) +def req_ok(resp): + def req_err(err): print(err, >>sys.stderr) - outstanding-- def req_fin(*args): + outstanding-- def check_outbound(): while True: @@ -83,7 +84,7 @@ def check_outbound(): hh = { 'User-Agent': ['hippotat'], 'Content-Type': ['multipart/form-data; boundary="b"'] } - req = agent.request('POST', + req = agent.request(b'POST', c.url, twisted.web.client.Headers(hh)) req.addTimeout(c.http_timeout,