Lines Matching refs:pid_file
4225 static void save_pid(const char *pid_file) { argument
4227 if (access(pid_file, F_OK) == 0) {
4228 if ((fp = fopen(pid_file, "r")) != NULL) {
4246 snprintf(tmp_pid_file, sizeof(tmp_pid_file), "%s.tmp", pid_file);
4258 if (rename(tmp_pid_file, pid_file) != 0) {
4260 tmp_pid_file, pid_file);
4264 static void remove_pidfile(const char *pid_file) { argument
4265 if (pid_file == NULL)
4268 if (unlink(pid_file) != 0) {
4269 vperror("Could not remove the pid file %s", pid_file);
4722 char *pid_file = NULL; local
5096 pid_file = optarg;
6187 if (pid_file != NULL) {
6188 save_pid(pid_file);
6234 remove_pidfile(pid_file);