diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-07-15 16:41:05 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-07-15 16:41:05 +0100 |
commit | 834573afd5cb9495d12d5945bea07f64a6cae540 (patch) | |
tree | ed5243a59ce5b33c7a0d0bd446337b9d9e79222f | |
parent | 6d11758e98e2adac29897cb45b7a243625d9b761 (diff) | |
download | rspamd-834573afd5cb9495d12d5945bea07f64a6cae540.tar.gz rspamd-834573afd5cb9495d12d5945bea07f64a6cae540.zip |
[Minor] Lua_task: Use absolute value when dealing with neural tokens
-rw-r--r-- | src/lua/lua_task.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lua/lua_task.c b/src/lua/lua_task.c index 1167edb50..9fe61e07d 100644 --- a/src/lua/lua_task.c +++ b/src/lua/lua_task.c @@ -4449,7 +4449,7 @@ lua_task_process_ann_tokens (lua_State *L) !(rspamd_symcache_item_flags (sres->sym->cache_item) & SYMBOL_TYPE_NOSTAT)) { - lua_pushnumber (L, tanh (sres->score)); + lua_pushnumber (L, fabs (tanh (sres->score))); lua_rawseti (L, 3, offset + 1); } } |