logread: cleanup pid file handling