decouple use_syslog from pid_flags

Sometimes we need processes to run in the foreground to be supervised
and at the same time use syslog facility instead of logging its stdout,
stderr output
This commit is contained in:
Yousong Zhou
2017-08-01 22:59:38 -07:00
committed by Max Lv
parent 28cf0ac1a5
commit db1728c76d
7 changed files with 22 additions and 12 deletions
+1 -1
View File
@@ -1726,8 +1726,8 @@ main(int argc, char **argv)
}
#endif
USE_SYSLOG(argv[0], pid_flags);
if (pid_flags) {
USE_SYSLOG(argv[0]);
daemonize(pid_path);
}