Otherwise, we may override the limits set by PAM.
Bug #894
}
#endif
- /* Restore coredumpsize resource limit before running. */
- if (sudo_conf_disable_coredump())
- disable_coredump(true);
-
if (details->pw != NULL) {
#ifdef HAVE_PROJECT_H
set_project(details->pw);
}
}
+ /*
+ * Restore coredumpsize resource limit before running.
+ * We must do this *before* calling the PAM session module.
+ */
+ if (sudo_conf_disable_coredump())
+ disable_coredump(true);
+
/*
* Run the command in a new pty if there is an I/O plugin or the policy
* has requested a pty. If /dev/tty is unavailable and no I/O plugin