From 4d9450192f52443303b72e9cbd5a9b9d0ac7807f Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Thu, 3 Apr 2014 12:43:14 +0100 Subject: [PATCH] Fix misusage of ip object. --- src/plugins/lua/multimap.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/plugins/lua/multimap.lua b/src/plugins/lua/multimap.lua index 8b094aa80..aac0f5159 100644 --- a/src/plugins/lua/multimap.lua +++ b/src/plugins/lua/multimap.lua @@ -24,12 +24,12 @@ local function check_multimap(task) if rule['type'] == 'ip' then if rule['cdb'] then local ip = task:get_from_ip() - if ip:is_valid() and rule['hash']:lookup(ip) then + if ip:is_valid() and rule['hash']:lookup(ip:to_string()) then task:insert_result(rule['symbol'], 1) end else - local ip = task:get_from_ip():to_number() - if ip:is_valid() and rule['ips'] and rule['ips']:get_key(ip) then + local ip = task:get_from_ip() + if ip:is_valid() and rule['ips'] and rule['ips']:get_key(ip:to_number()) then task:insert_result(rule['symbol'], 1) end end -- 2.39.5