Fix pidfile reading issue (string instead of int)