The Unbuntu version of Dspam has a nice tweak which
means that when its run with the --daemon option it
goes into the background.
I'm running Ubuntu 6 LTS which is running an old
version of spam.
So I grabbed the source and I've found the tweak which
others might like.
In dspam.c find the code that looks like:
DRIVER_CTX DTX;
char *pidfile;
__daemon_run = 1;
__num_threads = 0;
__hup = 0;
and change it to:
DRIVER_CTX DTX;
char *pidfile;
/* Fork dspam into the background */
if (fork()) {
exit(EXIT_SUCCESS);
}
__daemon_run = 1;
__num_threads = 0;
__hup = 0;
And it will now automatically fork into the background
when you use --daemon.
___________________________________________________________
Rise to the challenge for Sport Relief with Yahoo! For Good
http://uk.promotions.yahoo.com/forgood/