aboutsummaryrefslogtreecommitdiff
path: root/src/com_start.c
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org>2020-09-09 16:58:55 +0300
committerSergey Poznyakoff <gray@gnu.org>2020-09-09 17:03:22 +0300
commitaeef348db666ab537054a6ab48a75586fc7c6733 (patch)
treed3c0ef042714e825a4974c7e74e2b9df66fa5db8 /src/com_start.c
parent04f9616cbcbdb486d0832f4e8c35e74a08e266c5 (diff)
downloadgenrc-aeef348db666ab537054a6ab48a75586fc7c6733.tar.gz
genrc-aeef348db666ab537054a6ab48a75586fc7c6733.tar.bz2
Configurable syslog facility and tag.
* src/genrc.c: New options --log-facility and --log-tag. (genrc_openlog): New function. * src/genrc.h (genrc_openlog): New proto. * src/com_start.c (spawn): Use genrc_openlog. * src/sentinel.c (wait_loop): Use genrc_openlog. * NEWS: Update. * src/genrc.8: Update.
Diffstat (limited to 'src/com_start.c')
-rw-r--r--src/com_start.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com_start.c b/src/com_start.c
index 17581cb..5ad1786 100644
--- a/src/com_start.c
+++ b/src/com_start.c
@@ -1,5 +1,5 @@
/* This file is part of genrc
-Copyryght (C) 2018, 2019 Sergey Poznyakoff
+Copyryght (C) 2018-2020 Sergey Poznyakoff
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
@@ -127,7 +127,7 @@ spawn(int *p)
execvp(argv[0], argv);
if (p) {
- openlog(genrc_program, LOG_PID, LOG_DAEMON);
+ genrc_openlog();
syslog(LOG_CRIT, "failed to exec: %m");
} else
system_error(errno, "failed to exec %s", genrc_program);

Return to:

Send suggestions and report system problems to the System administrator.