changeset 2464:01babf1caa4a

mod_firewall: Fix $<> expressions being truncated when compiled
author Matthew Wild <mwild1@gmail.com>
date Thu, 26 Jan 2017 18:04:59 +0000 (2017-01-26)
parents e2d955f6167f
children bd69ffe071e6
files mod_firewall/mod_firewall.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mod_firewall/mod_firewall.lua	Wed Jan 25 10:34:50 2017 +0100
+++ b/mod_firewall/mod_firewall.lua	Thu Jan 26 18:04:59 2017 +0000
@@ -64,7 +64,7 @@
 			if expr:match("^@") then
 				return "\"..(stanza.attr["..("%q"):format(expr:sub(2)).."] or "..("%q"):format(default)..")..\"";
 			end
-			return "\"..(stanza:find("..("%q"):format(expr:sub(2, -2))..") or "..("%q"):format(default)..")..\"";
+			return "\"..(stanza:find("..("%q"):format(expr)..") or "..("%q"):format(default)..")..\"";
 		end)
 		:gsub("$$(%a+)", extra or {})
 		:gsub([[^""%.%.]], "")