Don't disable the creation of core files
Creation of core files can be disabled in the OS environment such as by using the ulimit program.
This commit is contained in:
parent
a37a81db2d
commit
448c19077c
@ -176,18 +176,6 @@ main(int argc, char **argv)
|
|||||||
struct group *thisgroup = NULL;
|
struct group *thisgroup = NULL;
|
||||||
FILE *config_file;
|
FILE *config_file;
|
||||||
|
|
||||||
/*
|
|
||||||
* Disable the creation of CORE files right up front.
|
|
||||||
*/
|
|
||||||
#if defined(HAVE_SETRLIMIT) && defined(NDEBUG)
|
|
||||||
struct rlimit core_limit = { 0, 0 };
|
|
||||||
if (setrlimit(RLIMIT_CORE, &core_limit) < 0) {
|
|
||||||
fprintf(stderr, "%s: Could not set the core limit to zero.\n",
|
|
||||||
argv[0]);
|
|
||||||
exit(EX_SOFTWARE);
|
|
||||||
}
|
|
||||||
#endif /* HAVE_SETRLIMIT */
|
|
||||||
|
|
||||||
/* Only allow u+rw bits. This may be required for some versions
|
/* Only allow u+rw bits. This may be required for some versions
|
||||||
* of glibc so that mkstemp() doesn't make us vulnerable.
|
* of glibc so that mkstemp() doesn't make us vulnerable.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user