title: GAE CGI: how to response http status code
body: <p>I am using google appening, it's CGI environment. I want block some request, I want response nothing  even no http status code. Alternative, I want just close the connection. Can I do this?</p>
  
  <p>update:</p>
  
  <p>I have decide to use what pyfunc said, use 204 status, but how can I do this at GAE CGI environment <strong>without any webframework.</strong></p>
  
  <p>update 2:</p>
  
  <p>Thanks a lot, but... I really need a CGI way, not WSGI way. Please see the comment in my codes.</p>
  
  <pre><code>def main()
    #Block requests at once.
    if (settings.BLOCK_DOWNLOAD and os.environ.get('HTTP_RANGE')) \
          or (settings.BLOCK_EXTENSION.match(os.environ['PATH_INFO'])):
      #TODO: return 204 response in CGI way.
      #I really do not need construct a WSGIApplication and then response a status code.
      return
  
    application = webapp.WSGIApplication([
      (r'/', MainHandler),
      #...
      ], debug=True)
    run_wsgi_app(application)
  
  
  if __name__ == '__main__':
    main()
  </code></pre>