|
[
Permlink
| « Hide
]
Graham Dumpleton added a comment - 13/Aug/06 10:29 AM
Another candidate for 3.3. Fix should be pretty simple, just need to adapt the original proposed change as posted on mailing list back in 2001.
Graham Dumpleton made changes - 13/Aug/06 10:29 AM
Does this patch seem correct for current implementation of util.FieldStorage?
Index: lib/python/mod_python/util.py =================================================================== --- lib/python/mod_python/util.py (revision 442143) +++ lib/python/mod_python/util.py (working copy) @@ -174,6 +174,10 @@ skip_this_part = False while line not in ('\r','\r\n'): + nextline = req.readline(readBlockSize) + while nextline and nextline[0] in [ ' ', '\t']: + line = line + nextline + nextline = req.readline(readBlockSize) # we read the headers until we reach an empty line # NOTE : a single \n would mean the entity is malformed, but # we're tolerating it anyway @@ -192,7 +196,7 @@ if ctype.find('/') == -1: ctype = 'application/octet-stream' - line = req.readline(readBlockSize) + line = nextline match = boundary.match(line) if (not line) or match: # we stop if we reached the end of the stream or a stop boundary Indenting got stuffed up when pasted in for some reason. Have attached possible patch instead.
Graham Dumpleton made changes - 11/Sep/06 12:01 PM
Graham Dumpleton made changes - 02/Oct/06 01:49 AM
Graham Dumpleton made changes - 02/Oct/06 01:49 AM
Graham Dumpleton made changes - 02/Oct/06 03:09 AM
Graham Dumpleton made changes - 17/Apr/07 10:29 AM
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||