[fix] Ensure hostname is freed.