diff options
| author | Russell Keith-Magee <russell@keith-magee.com> | 2009-09-12 22:05:23 +0000 |
|---|---|---|
| committer | Russell Keith-Magee <russell@keith-magee.com> | 2009-09-12 22:05:23 +0000 |
| commit | 39c53b4bf383214cf2bfa034b2ba684057d9ff25 (patch) | |
| tree | 871fe5da56519b491a221f08ecf249503ce316ed /django/core/handlers/modpython.py | |
| parent | f03a1ab1b167b731d6eb536481605669731e162a (diff) | |
[1.1.X] Fixed #11660 -- Corrected the CONTENT_TYPE and CONTENT_LENGTH headers provided by the mod_python handler. Thanks to Nowell Strite and Tareque Hossain for the report and fix.
Merge of r11528 from trunk.
git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.1.X@11530 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/core/handlers/modpython.py')
| -rw-r--r-- | django/core/handlers/modpython.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/core/handlers/modpython.py b/django/core/handlers/modpython.py index c6dcf23e9a..b1e3e17227 100644 --- a/django/core/handlers/modpython.py +++ b/django/core/handlers/modpython.py @@ -134,8 +134,8 @@ class ModPythonRequest(http.HttpRequest): if not hasattr(self, '_meta'): self._meta = { 'AUTH_TYPE': self._req.ap_auth_type, - 'CONTENT_LENGTH': self._req.clength, # This may be wrong - 'CONTENT_TYPE': self._req.content_type, # This may be wrong + 'CONTENT_LENGTH': self._req.headers_in.get('content-length', 0), + 'CONTENT_TYPE': self._req.headers_in.get('content-type'), 'GATEWAY_INTERFACE': 'CGI/1.1', 'PATH_INFO': self.path_info, 'PATH_TRANSLATED': None, # Not supported |
