Use getpwuid_r with the right signature, if available.