diff options
author | Rob Austein <sra@hactrn.net> | 2009-04-29 00:03:51 +0000 |
---|---|---|
committer | Rob Austein <sra@hactrn.net> | 2009-04-29 00:03:51 +0000 |
commit | 7476eb0d57f54eea047c2b9526e88753527bd0fa (patch) | |
tree | 79b6dc685d6a915f73d13f9f89f7dd022fae73a8 /rpkid/irdbd.py | |
parent | 08725383287522b6635ba0dc980bdc142f5e0882 (diff) |
First pass with pylint
svn path=/rpkid/Makefile; revision=2371
Diffstat (limited to 'rpkid/irdbd.py')
-rwxr-xr-x | rpkid/irdbd.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/rpkid/irdbd.py b/rpkid/irdbd.py index 8d7c7c2b..46669049 100755 --- a/rpkid/irdbd.py +++ b/rpkid/irdbd.py @@ -22,8 +22,7 @@ OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. """ -import sys, os, time, getopt, urlparse, traceback -import tlslite.api, MySQLdb, lxml.etree +import sys, os, time, getopt, urlparse, traceback, MySQLdb import rpki.https, rpki.config, rpki.resource_set, rpki.relaxng import rpki.exceptions, rpki.left_right, rpki.log, rpki.x509 @@ -72,7 +71,7 @@ def handler(query, path, cb): r_msg.append(r_pdu) - return 200, rpki.left_right.cms_msg.wrap(r_msg, irdbd_key, irdbd_cert) + cb(200, rpki.left_right.cms_msg.wrap(r_msg, irdbd_key, irdbd_cert)) except Exception, data: rpki.log.error(traceback.format_exc()) @@ -80,7 +79,7 @@ def handler(query, path, cb): # We only get here in cases where we couldn't or wouldn't generate # <report_error/>, so just return HTTP failure. - return 500, "Unhandled exception %s: %s" % (data.__class__.__name__, data) + cb(500, "Unhandled exception %s: %s" % (data.__class__.__name__, data)) os.environ["TZ"] = "UTC" time.tzset() |