Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

Commit

Permalink
base/icinga: Open debug log after dropping privileges
Browse files Browse the repository at this point in the history
refs #13709
  • Loading branch information
lazyfrosch committed Dec 21, 2016
1 parent 7c18062 commit 166c742
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions base/icinga.c
Expand Up @@ -678,9 +678,6 @@ int main(int argc, char **argv, char **env) {
my_free(mac->x[MACRO_PROCESSSTARTTIME]);
asprintf(&mac->x[MACRO_PROCESSSTARTTIME], "%lu", (unsigned long)program_start);

/* open debug log */
open_debug_log();

/* drop privileges */
if (drop_privileges(nagios_user, nagios_group) == ERROR) {

Expand All @@ -690,6 +687,9 @@ int main(int argc, char **argv, char **env) {
exit(ERROR);
}

/* open debug log */
open_debug_log();

#ifdef USE_EVENT_BROKER
/* initialize modules */
neb_init_modules();
Expand Down

0 comments on commit 166c742

Please sign in to comment.