commit 685cd2c: [Fix] Oops, fix math.huge invocation
Vsevolod Stakhov
vsevolod at highsecure.ru
Fri Oct 18 18:21:09 UTC 2019
Author: Vsevolod Stakhov
Date: 2019-10-18 19:16:39 +0100
URL: https://github.com/rspamd/rspamd/commit/685cd2ca4567a6984b74253c9f06328905ecfbf6 (HEAD -> master)
[Fix] Oops, fix math.huge invocation
Issue: #3099
---
lualib/lua_meta.lua | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lualib/lua_meta.lua b/lualib/lua_meta.lua
index b7c9286d7..4f4a6e3ac 100644
--- a/lualib/lua_meta.lua
+++ b/lualib/lua_meta.lua
@@ -455,7 +455,7 @@ local function rspamd_gen_metatokens(task, names)
for i,tok in ipairs(ct) do
lua_util.debugm(N, task, "metatoken: %s = %s",
mt.names[i], tok)
- if tok ~= tok or tok == math.huge() then
+ if tok ~= tok or tok == math.huge then
logger.errx(task, 'metatoken %s returned %s; replace it with 0 for sanity',
mt.names[i], tok)
tok = 0.0
@@ -471,7 +471,7 @@ local function rspamd_gen_metatokens(task, names)
for _,n in ipairs(names) do
if metatokens_by_name[n] then
local tok = metatokens_by_name[n](task)
- if tok ~= tok or tok == math.huge() then
+ if tok ~= tok or tok == math.huge then
logger.errx(task, 'metatoken %s returned %s; replace it with 0 for sanity',
n, tok)
tok = 0.0
@@ -495,7 +495,7 @@ local function rspamd_gen_metatokens_table(task)
for _,mt in ipairs(metafunctions) do
local ct = mt.cb(task)
for i,tok in ipairs(ct) do
- if tok ~= tok or tok == math.huge() then
+ if tok ~= tok or tok == math.huge then
logger.errx(task, 'metatoken %s returned %s; replace it with 0 for sanity',
mt.names[i], tok)
tok = 0.0
More information about the Commits
mailing list