diff options
-rw-r--r-- | Lib/CGIHTTPServer.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/CGIHTTPServer.py b/Lib/CGIHTTPServer.py index bb8cb2d..24bdeef 100644 --- a/Lib/CGIHTTPServer.py +++ b/Lib/CGIHTTPServer.py @@ -133,7 +133,10 @@ class CGIHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler): # AUTH_TYPE # REMOTE_USER # REMOTE_IDENT - env['CONTENT_TYPE'] = self.headers.type + if self.headers.typeheader is None: + env['CONTENT_TYPE'] = self.headers.type + else: + env['CONTENT_TYPE'] = self.headers.typeheader length = self.headers.getheader('content-length') if length: env['CONTENT_LENGTH'] = length |