Expand pid names properly