reacquire pid if it changes while running