Message182973
+ if bad_header_value_re.search(_value):
+ error_str = "Bad header value: {0!r} (bad char: {1!r})"
+ raise AssertionError(error_str.format(
+ _value, bad_header_value_re.search(_value).group(0)))
Why do you search the character twice? You can do something like:
match = bad_header_value_re.search(_value)
if match is not None:
... match..group(0) ...
Why do you only check value? You should also check _params:
parts = "; ".join(parts)
match = bad_header_value_re.search(parts)
...
And you should also check the name.
Should we do the same checks in httplib? |
|
Date |
User |
Action |
Args |
2013-02-25 18:37:35 | vstinner | set | recipients:
+ vstinner, pje, devin, Felix.Gröbert |
2013-02-25 18:37:35 | vstinner | set | messageid: <1361817455.03.0.404836600469.issue11671@psf.upfronthosting.co.za> |
2013-02-25 18:37:35 | vstinner | link | issue11671 messages |
2013-02-25 18:37:34 | vstinner | create | |
|