From b0c74e7f5af9006149c7143aee78fad68576181f Mon Sep 17 00:00:00 2001 From: eneq123 Date: Wed, 11 Feb 2015 16:10:21 +0300 Subject: [PATCH] real_ip to_string should not nil --- src/plugins/lua/once_received.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/lua/once_received.lua b/src/plugins/lua/once_received.lua index 3631aaacc..35c509bad 100644 --- a/src/plugins/lua/once_received.lua +++ b/src/plugins/lua/once_received.lua @@ -48,10 +48,10 @@ local function check_quantity_received (task) if not r['real_hostname'] or string.lower(r['real_hostname']) == 'unknown' or string.match(r['real_hostname'], '^%d+%.%d+%.%d+%.%d+$') then - if r['real_ip'] then + if r['real_ip'] and r['real_ip']:to_string() then -- Try to resolve it again task:get_resolver():resolve_ptr(task:get_session(), task:get_mempool(), - tostring(r['real_ip']), recv_dns_cb) + r['real_ip']:to_string(), recv_dns_cb) else task:insert_result(symbol_strict, 1) end -- 2.39.5