Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Changeset 2450

Show
Ignore:
Timestamp:
06/14/09 23:48:18
Author:
visteya
Message:

fix for #928, custom error page returning an iterable results in bad Content-Length

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/python3/cherrypy/_cperror.py

    r2430 r2450  
    224224            tb = format_exc() 
    225225        response.headers['Content-Type'] = "text/html;charset=utf-8" 
     226        response.headers.pop('Content-Length', None) 
    226227         
    227228        content = self.get_error_page(self.status, traceback=tb, 
    228229                                      message=self._message).encode('utf-8') 
    229230        response.body = content 
    230         response.headers['Content-Length'] = len(content) 
    231231         
    232232        _be_ie_unfriendly(self.code) 

Hosted by WebFaction

Log in as guest/cpguest to create tickets