Show More
@@ -17,6 +17,8 b" if '--twice' in sys.argv:" | |||
|
17 | 17 | sys.argv.remove('--twice') |
|
18 | 18 | twice = True |
|
19 | 19 | |
|
20 | reasons = {'Not modified': 'Not Modified'} # python 2.4 | |
|
21 | ||
|
20 | 22 | tag = None |
|
21 | 23 | def request(host, path, show): |
|
22 | 24 | |
@@ -28,7 +30,7 b' def request(host, path, show):' | |||
|
28 | 30 | conn = httplib.HTTPConnection(host) |
|
29 | 31 | conn.request("GET", path, None, headers) |
|
30 | 32 | response = conn.getresponse() |
|
31 | print response.status, response.reason | |
|
33 | print response.status, reasons.get(response.reason, response.reason) | |
|
32 | 34 | for h in [h.lower() for h in show]: |
|
33 | 35 | if response.getheader(h, None) is not None: |
|
34 | 36 | print "%s: %s" % (h, response.getheader(h)) |
General Comments 0
You need to be logged in to leave comments.
Login now