Ticket #8259: patch.diff
File patch.diff, 863 bytes (added by , 16 years ago) |
---|
-
django/core/handlers/wsgi.py
173 173 try: 174 174 # CONTENT_LENGTH might be absent if POST doesn't have content at all (lighttpd) 175 175 content_length = int(self.environ.get('CONTENT_LENGTH', 0)) 176 except ValueError: # if CONTENT_LENGTH was empty string or not an integer 176 except (ValueError, TypeError): 177 # If CONTENT_LENGTH was empty string, None or not an integer. 178 # It ought not to be None, but that has been reported (see #8259) hence TypeError. 177 179 content_length = 0 178 180 if content_length > 0: 179 181 safe_copyfileobj(self.environ['wsgi.input'], buf,