From 9e15dd6861602449e21024d18214f6da0bbe3df7 Mon Sep 17 00:00:00 2001 From: Johannes Gijsbers Date: Sat, 14 Aug 2004 15:39:34 +0000 Subject: [PATCH] Let cgi.parse_header() properly unquote headers (patch #1008597). --- Lib/cgi.py | 1 + 1 file changed, 1 insertion(+) diff --git a/Lib/cgi.py b/Lib/cgi.py index 7c3d6579434..fb40ed36a3c 100755 --- a/Lib/cgi.py +++ b/Lib/cgi.py @@ -338,6 +338,7 @@ def parse_header(line): value = p[i+1:].strip() if len(value) >= 2 and value[0] == value[-1] == '"': value = value[1:-1] + value = value.replace('\\\\', '\\').replace('\\"', '"') pdict[name] = value return key, pdict