[mod_python] _apache.parse_qsl is buggy (mod_python2.7.2)

Brian Hawthorne brianh at exelixis.com
Wed Mar 14 11:45:40 EST 2001


i thought it would be useful to point out (mod_python2.7.2) that this
function, implemented in _apachemodule.c, which should support the same
interface and functionality as the standard python cgi.parse_qsl, does not
correctly parse form values from an ampersand delimited string of
key=value pairs.  sometimes it simply drops some pairs, other times it
mangles the keys and/or values.  i worked around this by adding to 
line 110 of mod_python/util.py:
            import cgi
            pairs = cgi.parse_qsl(req.args, keep_blank_values=1)

brian hawthorne
Associate Informatics Research Scientist
Exelixis, Inc.





More information about the Mod_python mailing list