}
}
-static void daemonize (const char *lockfile, char *tty, char *name)
+static void daemonize (const char *lockfile, char *tty)
{
pid_t pid, sid, parent;
int lfp = -1;
}
pFile = fopen (pidfile,"w");
- if (pFile < 0)
+ if (pFile == NULL)
{
syslog (LOG_ERR, "unable to create pid file %s, code=%d (%s)",
pidfile, errno, strerror (errno));
syslog (LOG_INFO, "starting on TTY device %s", ttypath);
/* Daemonize */
- daemonize ("/var/lock/" DAEMON_NAME, tty, name);
+ daemonize ("/var/lock/" DAEMON_NAME, tty);
/* Now we are a daemon -- do the work for which we were paid */
int fd;