From d81da2c8a9a5ec501104aad1734bd7a0548648e3 Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Wed, 7 May 2014 18:13:22 +0200 Subject: [PATCH] Fixed form-parsing bug. --- wrw/form.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wrw/form.py b/wrw/form.py index a57a812..53fc82d 100644 --- a/wrw/form.py +++ b/wrw/form.py @@ -7,7 +7,7 @@ def formparse(req): buf = {} buf.update(urllib.parse.parse_qsl(req.query)) if req.ihead.get("Content-Type") == "application/x-www-form-urlencoded": - rbody = req.input(2 ** 20) + rbody = req.input.read(2 ** 20) if len(rbody) >= 2 ** 20: raise ValueError("x-www-form-urlencoded data is absurdly long") buf.update(urllib.parse.parse_qsl(rbody.decode("latin1"))) -- 2.11.0