From 69eb6cbefcf769276e3e15c6f20e9d5af74fd326 Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Sun, 19 Mar 2017 18:15:03 +0100 Subject: [PATCH] Properly quote percent-signs in URLs. --- wrw/proto.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wrw/proto.py b/wrw/proto.py index 8174f9e..482a23e 100644 --- a/wrw/proto.py +++ b/wrw/proto.py @@ -106,7 +106,7 @@ def urlq(url): if isinstance(url, str): url = url.encode("utf-8") ret = "" - invalid = b";&=#?/\"'" + invalid = b"%;&=#?/\"'" for c in url: if c in invalid or (c <= 32) or (c >= 128): ret += "%%%02X" % c -- 2.11.0