commit a486435: [Minor] Improve debug logging

Vsevolod Stakhov vsevolod at highsecure.ru
Fri Jul 16 13:07:04 UTC 2021


Author: Vsevolod Stakhov
Date: 2021-07-16 14:02:43 +0100
URL: https://github.com/rspamd/rspamd/commit/a4864356682637d4bede27a618e4da0097162cb5 (HEAD -> master)

[Minor] Improve debug logging

---
 src/libserver/composites/composites.cxx | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/libserver/composites/composites.cxx b/src/libserver/composites/composites.cxx
index 8614f4a12..1d3c13a97 100644
--- a/src/libserver/composites/composites.cxx
+++ b/src/libserver/composites/composites.cxx
@@ -766,8 +766,9 @@ rspamd_composite_expr_process(void *ud, rspamd_expression_atom_t *atom) -> doubl
 		}
 	}
 
-	msg_debug_composites ("%s: final result for composite %s is %.4f",
+	msg_debug_composites ("%s: result for atom %s in composite %s is %.4f",
 			cd->metric_res->name,
+			comp_atom->norm_symbol.data(),
 			cd->composite->sym.c_str(), rc);
 
 	return rc;
@@ -826,6 +827,10 @@ composites_foreach_callback(gpointer key, gpointer value, void *data)
 			/* Checked bit */
 			cd->checked[comp->id * 2] = true;
 
+			msg_debug_composites ("%s: final result for composite %s is %.4f",
+					cd->metric_res->name,
+					cd->composite->sym.c_str(), rc);
+
 			/* Result bit */
 			if (fabs(rc) > epsilon) {
 				cd->checked[comp->id * 2 + 1] = true;


More information about the Commits mailing list