* Enable core dumps regardless of system ulimit setting
[citadel.git] / citadel / sysdep.c
index aea5614cdcb4eadf0335a52954873f6b016b0f35..f0e9dc45754d25d2cb3482169c867b059d726fc2 100644 (file)
@@ -206,6 +206,10 @@ static RETSIGTYPE signal_cleanup(int signum) {
 void init_sysdep(void) {
        int a;
 
+       /* Enable core dumps */
+       struct rlimit lim = { RLIM_INFINITY, RLIM_INFINITY };
+       setrlimit(RLIMIT_CORE, &lim);
+
 #ifdef HAVE_OPENSSL
        init_ssl();
 #endif