Skip to content

Commit

Permalink
Bug Fix: Properly initialize static and env events
Browse files Browse the repository at this point in the history
  • Loading branch information
Theldus committed Sep 25, 2024
1 parent cf9a927 commit 0ae977a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion alertik.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ static void *handle_messages(void *p)
int main(void)
{
pthread_t handler;
int ret;
int fd;

log_init();
Expand All @@ -55,7 +56,9 @@ int main(void)
log_msg(" (https://github.com/Theldus/alertik)\n");
log_msg("-------------------------------------------------\n");

if (!init_static_events() && !init_environment_events())
ret = init_static_events();
ret += init_environment_events();
if (!ret)
panic("No event was configured, please configure at least one\n"
"before proceeding!\n");

Expand Down

0 comments on commit 0ae977a

Please sign in to comment.