]> source.dussan.org Git - rspamd.git/commitdiff
real_ip to_string should not nil
authoreneq123 <you@example.com>
Wed, 11 Feb 2015 13:10:21 +0000 (16:10 +0300)
committereneq123 <you@example.com>
Wed, 11 Feb 2015 13:10:21 +0000 (16:10 +0300)
src/plugins/lua/once_received.lua

index 3631aaacc8d5557c2065fa2d458dd3e65ab01ccb..35c509badd9766fad3ff34556c8e418a328dea59 100644 (file)
@@ -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