mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-13 08:44:36 +02:00
Revert "fixup set rlimit stack failed condition"
This reverts commit bf959371c4505bfe27b0682611c035d64b90efd3. fixes #6257
This commit is contained in:
parent
0822a7b0ab
commit
0b1d5013ac
@ -239,10 +239,10 @@ void Application::SetResourceLimits()
|
||||
else
|
||||
rl.rlim_cur = rl.rlim_max;
|
||||
|
||||
if (setrlimit(RLIMIT_STACK, &rl) < 0) {
|
||||
if (setrlimit(RLIMIT_STACK, &rl) < 0)
|
||||
Log(LogWarning, "Application")
|
||||
<< "Failed adjust resource limit for stack size (RLIMIT_STACK) with error \"" << strerror(errno) << "\"";
|
||||
if (set_stack_rlimit) {
|
||||
else if (set_stack_rlimit) {
|
||||
char **new_argv = static_cast<char **>(malloc(sizeof(char *) * (argc + 2)));
|
||||
|
||||
if (!new_argv) {
|
||||
@ -267,7 +267,6 @@ void Application::SetResourceLimits()
|
||||
perror("execvp");
|
||||
_exit(EXIT_FAILURE);
|
||||
}
|
||||
}
|
||||
# else /* RLIMIT_STACK */
|
||||
Log(LogNotice, "Application", "System does not support adjusting the resource limit for stack size (RLIMIT_STACK)");
|
||||
# endif /* RLIMIT_STACK */
|
||||
|
Loading…
x
Reference in New Issue
Block a user