[PATCH v6 11/19] lib: Always set errno in hcreate_r