Lines Matching refs:pidfile
1800 static int check_existing_pidfile(const char *pidfile) in check_existing_pidfile() argument
1807 if (stat(pidfile, &sb)) in check_existing_pidfile()
1810 f = fopen(pidfile, "r"); in check_existing_pidfile()
1827 static int write_pid(pid_t pid, const char *pidfile) in write_pid() argument
1831 fpid = fopen(pidfile, "w"); in write_pid()
1833 log_err("fio: failed opening pid file %s\n", pidfile); in write_pid()
1845 int fio_start_server(char *pidfile) in fio_start_server() argument
1855 if (!pidfile) in fio_start_server()
1858 if (check_existing_pidfile(pidfile)) { in fio_start_server()
1860 pidfile); in fio_start_server()
1861 free(pidfile); in fio_start_server()
1868 free(pidfile); in fio_start_server()
1871 ret = write_pid(pid, pidfile); in fio_start_server()
1872 free(pidfile); in fio_start_server()
1888 unlink(pidfile); in fio_start_server()
1889 free(pidfile); in fio_start_server()