Hi,
src/deliver.c:1726 lists the following code:
/* Prevent core dumps, as we don't want them in users' home directories.
HP-UX doesn't have RLIMIT_CORE; I don't know how to do this in that
system. Some experimental/developing systems (e.g. GNU/Hurd) may define
RLIMIT_CORE but not support it in setrlimit(). For such systems, do not
complain if the error is "not supported". */
#ifdef RLIMIT_CORE
struct rlimit rl;
rl.rlim_cur = 0;
rl.rlim_max = 0;
if (setrlimit(RLIMIT_CORE, &rl) < 0)
Setting the rlim_max to zero makes it impossible to enable coredumps for
subprocesses. Setting rlim_cur to zero would be enough to prevent
coredumps; soft limits vs. hard limits.
I've the problem that I pass my mails to bogofilter via the systemfilter
and bogofilter crashes sometimes (#510793). I want to get a coredump of
the crashed process to further insprect the problem, but it's not
possible because the hardlimit is set to zero and the systemfilter is not
run by root.
--- deliver.c+ 2009-01-11 20:17:19.000000000 +0100
+++ deliver.c 2009-01-11 20:20:06.000000000 +0100
@@ -1731,8 +1731,9 @@
#ifdef RLIMIT_CORE
struct rlimit rl;
+ if (getrlimit(RLIMIT_CORE, &rl) < 0)
+ rl.rlim_max = 0;
rl.rlim_cur = 0;
- rl.rlim_max = 0;
if (setrlimit(RLIMIT_CORE, &rl) < 0)
{
#ifdef SETRLIMIT_NOT_SUPPORTED
Bye, Jörg.