diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-11-15 13:20:49 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-11-15 13:20:49 +0000 |
commit | 77b46f8ab8b468cb96c77558c71b2ca7b1c594a4 (patch) | |
tree | 011162e48a036c1cef579d37d92c5f311b6efad6 /src/libstat/stat_process.c | |
parent | d2f82b9a72ce34fdcb757e08072bcc2bef9cac28 (diff) | |
download | rspamd-77b46f8ab8b468cb96c77558c71b2ca7b1c594a4.tar.gz rspamd-77b46f8ab8b468cb96c77558c71b2ca7b1c594a4.zip |
[Fix] Properly set learned count
Diffstat (limited to 'src/libstat/stat_process.c')
-rw-r--r-- | src/libstat/stat_process.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/libstat/stat_process.c b/src/libstat/stat_process.c index 228b6b87b..87c5c3190 100644 --- a/src/libstat/stat_process.c +++ b/src/libstat/stat_process.c @@ -525,6 +525,12 @@ rspamd_stat_classifiers_process (struct rspamd_stat_ctx *st_ctx, return; } + for (i = 0; i < st_ctx->classifiers->len; i++) { + cl = g_ptr_array_index (st_ctx->classifiers, i); + cl->spam_learns = 0; + cl->ham_learns = 0; + } + for (i = 0; i < st_ctx->statfiles->len; i++) { st = g_ptr_array_index (st_ctx->statfiles, i); cl = st->classifier; |