(pidfile)
| 264 | |
| 265 | |
| 266 | def _create_pidlock(pidfile): |
| 267 | pidlock = Pidfile(pidfile) |
| 268 | if pidlock.is_locked() and not pidlock.remove_if_stale(): |
| 269 | print(PIDLOCKED.format(pidfile, pidlock.read_pid()), file=sys.stderr) |
| 270 | raise SystemExit(EX_CANTCREAT) |
| 271 | pidlock.acquire() |
| 272 | return pidlock |
| 273 | |
| 274 | |
| 275 | def fd_by_path(paths): |