aboutsummaryrefslogtreecommitdiffstats
path: root/src/client
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2014-11-14 15:53:34 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2014-11-14 15:53:34 +0000
commit91019d575c2b25a40bdb39de56ebea246ea950ce (patch)
treedc0ea03dc4306c08d8c0f05db951979390f05bc0 /src/client
parent8c1ba9d336729d2e18fde48fab8bd8fbce4e73af (diff)
downloadrspamd-91019d575c2b25a40bdb39de56ebea246ea950ce.tar.gz
rspamd-91019d575c2b25a40bdb39de56ebea246ea950ce.zip
Fix percents display in rspamc.
Diffstat (limited to 'src/client')
-rw-r--r--src/client/rspamc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/client/rspamc.c b/src/client/rspamc.c
index ecae8cbcc..4dd054725 100644
--- a/src/client/rspamc.c
+++ b/src/client/rspamc.c
@@ -631,16 +631,16 @@ rspamc_stat_actions (ucl_object_t *obj, GString *out, gint64 scanned)
gint64 cnt = ucl_object_toint (cur);
rspamd_printf_gstring (out, "Messages with action %s: %L"
", %.2f%%\n", ucl_object_key (cur), cnt,
- (gdouble)cnt / (gdouble)scanned);
+ ((gdouble)cnt / (gdouble)scanned) * 100.);
}
}
spam = ucl_object_toint (ucl_object_find_key (obj, "spam_count"));
ham = ucl_object_toint (ucl_object_find_key (obj, "ham_count"));
rspamd_printf_gstring (out, "Messages treated as spam: %L, %.2f%%\n", spam,
- (gdouble)spam / (gdouble)scanned);
+ ((gdouble)spam / (gdouble)scanned) * 100.);
rspamd_printf_gstring (out, "Messages treated as ham: %L, %.2f%%\n", ham,
- (gdouble)ham / (gdouble)scanned);
+ ((gdouble)ham / (gdouble)scanned) * 100.);
}
static void