From 82666876f8d1532f801e098d3efcbd31bc8d3a47 Mon Sep 17 00:00:00 2001 From: Radek Doulik Date: Mon, 21 Jun 2004 17:14:37 +0000 Subject: (em_junk_sa_test_spamd): try to get spamd/spamc binaries from gconf Implements #59368 svn path=/trunk/; revision=26442 --- mail/em-junk-filter.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'mail/em-junk-filter.c') diff --git a/mail/em-junk-filter.c b/mail/em-junk-filter.c index 338dd5d931..3c9627af66 100644 --- a/mail/em-junk-filter.c +++ b/mail/em-junk-filter.c @@ -273,9 +273,25 @@ em_junk_sa_test_spamd (void) char *spamc_binaries [3] = {"spamc", "/usr/sbin/spamc", NULL}; char *spamd_binaries [3] = {"spamd", "/usr/sbin/spamd", NULL}; + if (em_junk_sa_gconf) { + char *binary; + + binary = gconf_client_get_string (em_junk_sa_gconf, "/apps/evolution/mail/junk/sa/spamc_binary", NULL); + if (binary) { + spamc_binaries [0] = binary; + spamc_binaries [1] = NULL; + } + binary = gconf_client_get_string (em_junk_sa_gconf, "/apps/evolution/mail/junk/sa/spamd_binary", NULL); + if (binary) { + spamd_binaries [0] = binary; + spamd_binaries [1] = NULL; + try_system_spamd = FALSE; + } + } + em_junk_sa_use_spamc = FALSE; - if (em_junk_sa_local_only) { + if (em_junk_sa_local_only && try_system_spamd) { i = 0; argv [i++] = "/bin/sh"; argv [i++] = "-c"; -- cgit