From: Jo-Philipp Wich Date: Mon, 23 Jun 2008 19:20:57 +0000 (+0000) Subject: * luci/libs: fix possible error when doing sub() on chunk in server.lua X-Git-Tag: 0.8.0~784 X-Git-Url: https://git.archive.openwrt.org/?p=project%2Fluci.git;a=commitdiff_plain;h=520b4060a7474aab2f4a4b9b07872a38478d29c6 * luci/libs: fix possible error when doing sub() on chunk in server.lua --- diff --git a/libs/httpd/luasrc/httpd/server.lua b/libs/httpd/luasrc/httpd/server.lua index 2bb44bd02..2c415009e 100644 --- a/libs/httpd/luasrc/httpd/server.lua +++ b/libs/httpd/luasrc/httpd/server.lua @@ -124,7 +124,7 @@ function Server.create_client_sources(self, client) or "Unexpected EOF" -- Line ok - else + elseif chunk ~= nil -- Strip trailing CR chunk = chunk:gsub("\r$","")