From: Andrew Lewis Date: Wed, 8 Feb 2017 10:19:13 +0000 (+0200) Subject: [Fix] Lua IP from string should be invalid if parsing failed X-Git-Tag: 1.5.0~154^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fpull%2F1405%2Fhead;p=rspamd.git [Fix] Lua IP from string should be invalid if parsing failed --- diff --git a/src/lua/lua_ip.c b/src/lua/lua_ip.c index 0ebbf2003..0086e2b7a 100644 --- a/src/lua/lua_ip.c +++ b/src/lua/lua_ip.c @@ -361,6 +361,7 @@ lua_ip_from_string (lua_State *L) if (!rspamd_parse_inet_address (&ip->addr, ip_str, 0)) { msg_warn ("cannot parse ip: %s", ip_str); + ip->addr = NULL; } } else {