aboutsummaryrefslogtreecommitdiffstats
path: root/src/classifiers/bayes.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2013-06-09 15:47:34 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2013-06-09 15:47:34 +0100
commit48197c2ea1e4883a5b379c47fc3d50325f6269b8 (patch)
treeb68cd8ed52d6e84f689d31089019389c9bb6b505 /src/classifiers/bayes.c
parent7cc8754ad93be42cf7cd6f1cba68621c93accf89 (diff)
downloadrspamd-48197c2ea1e4883a5b379c47fc3d50325f6269b8.tar.gz
rspamd-48197c2ea1e4883a5b379c47fc3d50325f6269b8.zip
Test for expl function presence.
Diffstat (limited to 'src/classifiers/bayes.c')
-rw-r--r--src/classifiers/bayes.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/classifiers/bayes.c b/src/classifiers/bayes.c
index 77e02ea6b..f8aed3ac7 100644
--- a/src/classifiers/bayes.c
+++ b/src/classifiers/bayes.c
@@ -121,7 +121,11 @@ inv_chi_square (gdouble value, gint freedom_deg)
value /= 2.;
errno = 0;
+#ifdef HAVE_EXPL
prob = expl (-value);
+#else
+ prob = exp (-value);
+#endif
if (errno == ERANGE) {
msg_err ("exp overflow");
return 0;