Better pid handling.