commit 17827969b2da66ea4361b3ddf6c95adc84483de3 Author: David Fifield david@bamsoftware.com Date: Thu Aug 30 09:43:22 2012 -0700
Check for 200 response code in flashproxy-reg-http. --- flashproxy-reg-http | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/flashproxy-reg-http b/flashproxy-reg-http index ac45a30..4cff231 100755 --- a/flashproxy-reg-http +++ b/flashproxy-reg-http @@ -103,6 +103,9 @@ spec = format_addr(options.remote_addr) http = httplib.HTTPConnection(*options.facilitator_addr) try: http.request("POST", "/", urllib.urlencode({"client": spec})) + resp = http.getresponse() + if resp.status != 200: + raise ValueError("Status code was %d, not 200" % resp.status) except Exception, e: print >> sys.stderr, "Failed to register: %s" % str(e) sys.exit(1)
tor-commits@lists.torproject.org