init: fix double free of pid_file