[Python-checkins] python/dist/src/Lib CGIHTTPServer.py,1.34,1.35
gvanrossum at users.sourceforge.net
gvanrossum at users.sourceforge.net
Sat Mar 20 17:18:05 EST 2004
Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10624
Modified Files:
CGIHTTPServer.py
Log Message:
Fix for SF 777848.
I've been bitten by this myself in the past half year.
I hope this fix is right.
I'll backport this to 2.3.
Index: CGIHTTPServer.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/CGIHTTPServer.py,v
retrieving revision 1.34
retrieving revision 1.35
diff -C2 -d -r1.34 -r1.35
*** CGIHTTPServer.py 20 Mar 2004 21:51:12 -0000 1.34
--- CGIHTTPServer.py 20 Mar 2004 22:18:03 -0000 1.35
***************
*** 178,187 ****
env['HTTP_COOKIE'] = ', '.join(co)
# XXX Other HTTP_* headers
! if not self.have_fork:
! # Since we're setting the env in the parent, provide empty
! # values to override previously set values
! for k in ('QUERY_STRING', 'REMOTE_HOST', 'CONTENT_LENGTH',
! 'HTTP_USER_AGENT', 'HTTP_COOKIE'):
! env.setdefault(k, "")
os.environ.update(env)
--- 178,186 ----
env['HTTP_COOKIE'] = ', '.join(co)
# XXX Other HTTP_* headers
! # Since we're setting the env in the parent, provide empty
! # values to override previously set values
! for k in ('QUERY_STRING', 'REMOTE_HOST', 'CONTENT_LENGTH',
! 'HTTP_USER_AGENT', 'HTTP_COOKIE'):
! env.setdefault(k, "")
os.environ.update(env)
More information about the Python-checkins
mailing list