Lines Matching refs:pidfile
136 char buf[_POSIX2_LINE_MAX], *mstr, **pargv, *p, *q, *pidfile; in main() local
183 pidfile = NULL; in main()
195 pidfile = optarg; in main()
302 if (pidfile != NULL) in main()
303 pidfromfile = takepid(pidfile, pidfilelock); in main()
807 takepid(const char *pidfile, int pidfilelock) in takepid() argument
813 fh = fopen(pidfile, "r"); in takepid()
815 err(STATUS_ERROR, "Cannot open pidfile `%s'", pidfile); in takepid()
824 errx(STATUS_ERROR, "File '%s' can be locked", pidfile); in takepid()
828 "Error while locking file '%s'", pidfile); in takepid()
836 errx(STATUS_ERROR, "Pidfile `%s' is empty", pidfile); in takepid()
839 err(STATUS_ERROR, "Cannot read from pid file `%s'", pidfile); in takepid()
845 errx(STATUS_ERROR, "Invalid pid in file `%s'", pidfile); in takepid()
847 errx(STATUS_ERROR, "Invalid pid in file `%s'", pidfile); in takepid()