From 4495368d9e32697ea9d691975de283cb737fb60a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 19 May 2015 16:53:29 +0530 Subject: [PATCH] Dont force the handler to set a status code --- src/calibre/srv/http.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/srv/http.py b/src/calibre/srv/http.py index aa13222fd3..95f21f4012 100644 --- a/src/calibre/srv/http.py +++ b/src/calibre/srv/http.py @@ -508,7 +508,7 @@ class HTTPPair(object): # Read and discard any remaining body from the HTTP request self.input_reader.read() if self.status_code is None: - raise Exception('Request handler did not set status_code') + self.status_code = httplib.OK try: self.status_code, output = finalize_output(output, self.inheaders, self.outheaders, self.status_code, self.response_protocol is HTTP1, self.method)