New commit. Much changes. Very impress. Wow.
This commit is contained in:
parent
6eb419202c
commit
eb041ce5b4
5 changed files with 65 additions and 9 deletions
4
siahsd.c
4
siahsd.c
|
@ -126,8 +126,10 @@ int main(int argc, char **argv) {
|
|||
if ((pid = fork())) {
|
||||
/* Write PID file */
|
||||
pidfile = fopen(conf->pid_file, "w");
|
||||
if (pidfile < 0)
|
||||
if (pidfile == NULL) {
|
||||
DEBUG(0, "Cannot open pid file");
|
||||
return ST_LOG_ERR;
|
||||
}
|
||||
|
||||
n = fprintf(pidfile, "%d\n", pid);
|
||||
fclose(pidfile);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue