Go to the documentation of this file. 1 #ifndef foodaemonpidhfoo
2 #define foodaemonpidhfoo
24 #include <sys/types.h>
37 typedef const char* (*daemon_pid_file_proc_t)(void);
82 #define DAEMON_PID_FILE_KILL_WAIT_AVAILABLE 1
daemon_pid_file_proc_t daemon_pid_file_proc
A function pointer which is used to generate the name of the PID file to manipulate.
int daemon_pid_file_remove(void)
Removes the PID file of the current process.
pid_t daemon_pid_file_is_running(void)
Returns the PID file of a running daemon, if available.
int daemon_pid_file_kill_wait(int s, int m)
Similar to daemon_pid_file_kill() but waits until the process died.
const char * daemon_pid_file_ident
Identification string for the PID file name, only used when daemon_pid_file_proc is set to daemon_pid...
int daemon_pid_file_kill(int s)
Kills a running daemon, if available.
const char *(* daemon_pid_file_proc_t)(void)
Prototype of a function for generating the name of a PID file.
const char * daemon_pid_file_proc_default(void)
A function for creating a pid file name from daemon_pid_file_ident.
int daemon_pid_file_create(void)
Creates PID pid file for the current process.