aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-junk-filter.c
diff options
context:
space:
mode:
Diffstat (limited to 'mail/em-junk-filter.c')
-rw-r--r--mail/em-junk-filter.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/mail/em-junk-filter.c b/mail/em-junk-filter.c
index c0f5a28824..8a5623b191 100644
--- a/mail/em-junk-filter.c
+++ b/mail/em-junk-filter.c
@@ -189,8 +189,9 @@ em_junk_sa_test_spamd (void)
{
int port = SPAMD_PORT;
char *argv[6] = {
- "spamassassin",
- "--version",
+ "/bin/sh",
+ "-c",
+ "spamassassin --version",
NULL,
};
@@ -264,7 +265,7 @@ em_junk_sa_is_available (void)
static gboolean
em_junk_sa_check_junk (CamelMimeMessage *msg)
{
- char *argv[4], buf[12];
+ char *argv[5], buf[12];
int i = 0;
d(fprintf (stderr, "em_junk_sa_check_junk\n"));
@@ -281,10 +282,13 @@ em_junk_sa_check_junk (CamelMimeMessage *msg)
argv[i++] = buf;
}
} else {
- argv[i++] = "spamassassin";
- argv[i++] = "--exit-code";
+ argv[i++] = "/bin/sh";
+ argv[i++] = "-c";
+
if (mail_session_get_sa_local_only ())
- argv[i++] = "--local";
+ argv[i++] = "spamassassin --exit-code --local";
+ else
+ argv[i++] = "spamassassin --exit-code";
}
argv[i] = NULL;