From f62839fde97c1d59d22d4e3b8eee6bc85f2f2c0b Mon Sep 17 00:00:00 2001 From: Steven Barth Date: Fri, 5 Sep 2008 11:36:53 +0000 Subject: [PATCH] Fixed HTTP stack to parse urlencoded data from Internet Explorer correctly Internet Explorer appends a whitespace character after the last parameter which will now be stripped --- libs/http/luasrc/http/protocol.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/http/luasrc/http/protocol.lua b/libs/http/luasrc/http/protocol.lua index fd0a046f6..93c9e7999 100644 --- a/libs/http/luasrc/http/protocol.lua +++ b/libs/http/luasrc/http/protocol.lua @@ -500,7 +500,7 @@ function urldecode_message_body( src, msg ) if spos then local pair = data:sub( spos, epos - 1 ) local key = pair:match("^(.-)=") - local val = pair:match("=(.*)$") + local val = pair:match("=([^%s]*)%s*$") if key and #key > 0 then __initval( msg.params, key ) -- 2.11.0