diff options
author | ianb <devnull@localhost> | 2007-05-25 02:23:18 +0000 |
---|---|---|
committer | ianb <devnull@localhost> | 2007-05-25 02:23:18 +0000 |
commit | 8451a9b6741d615075ee97a560c4173a4e25c862 (patch) | |
tree | a625bf507775611516af2b40f4bc1281f1890f77 /paste/httpheaders.py | |
parent | e9b8a9c9176ddbcc4a6e4c8073740d4f00120231 (diff) | |
download | paste-8451a9b6741d615075ee97a560c4173a4e25c862.tar.gz |
Fix #179, exception for accept-languages
Diffstat (limited to 'paste/httpheaders.py')
-rw-r--r-- | paste/httpheaders.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/paste/httpheaders.py b/paste/httpheaders.py index 8c21be9..c216783 100644 --- a/paste/httpheaders.py +++ b/paste/httpheaders.py @@ -958,6 +958,9 @@ class _AcceptLanguage(_MultiValueHeader): lang, params = pieces[0].strip().lower(), pieces[1:] q = 1 for param in params: + if '=' not in param: + # Malformed request; probably a bot, we'll ignore + continue lvalue, rvalue = param.split("=") lvalue = lvalue.strip().lower() rvalue = rvalue.strip() |