Improved process comparison, so it uses more than just pid.