'A horrible, horrible way to kill the server for Python 2.6 and
later.  It\'s the best we can do.'

def initiate_shutdown(self):

    sig = getattr(signal, 'SIGKILL', signal.SIGTERM)
    if (os.environ.get('WERKZEUG_RUN_MAIN') == 'true'):
        os.kill(os.getpid(), sig)
    self.server._BaseServer__shutdown_request = True
    self.server._BaseServer__serving = False
