Commits

Chris McDonough committed 8d83a49

allow ctrl-C to work; fix typo in wsgiserver2.py (level= vs. level-)

Comments (0)

Files changed (2)

cherrypy/wsgiserver/wsgiserver2.py

         while self.ready:
             try:
                 self.tick()
+            except KeyboardInterrupt, e:
+                self.interrupt = e
             except:
-                self.error_log("Error in HTTPServer.tick", level-logging.ERROR,
+                self.error_log("Error in HTTPServer.tick", level=logging.ERROR,
                                traceback=True)
             
             if self.interrupt:

cherrypy/wsgiserver/wsgiserver3.py

         while self.ready:
             try:
                 self.tick()
+            except KeyboardInterrupt as e:
+                self.interrupt = e
             except:
                 self.error_log("Error in HTTPServer.tick", level=logging.ERROR,
                                traceback=True)