title: How to stop the tornado web server with ctrl+c?
body: <p>I am new to tornado web server. When I start the tornado web server using python main_tornado.py It is working. Please see the below code.</p>
  
  <pre><code>import tornado.ioloop
  import tornado.web
  
  class MainHandler(tornado.web.RequestHandler):
      def get(self):
          self.write("Hello, world")
  
  application = tornado.web.Application([
      (r"/", MainHandler),
  ])
  
  if __name__ == "__main__":
      application.listen(8888)
      tornado.ioloop.IOLoop.instance().start()
  </code></pre>
  
  <p>When I stop the server using CTRL+C it gave the following error.</p>
  
  <pre><code>    ^CTraceback (most recent call last):
    File "main_tornado.py", line 19, in &lt;module&gt;
      tornado.ioloop.IOLoop.instance().start()
    File "/home/nyros/Desktop/NewWeb/venv/lib/python3.2/site-packages/tornado/ioloop.py", line 301, in start
      event_pairs = self._impl.poll(poll_timeout)
  KeyboardInterrupt
  </code></pre>
  
  <p>Please solve my problem. Thanks..</p>