Change slurm_xrealloc() to slurm_recalloc(). Add xrecalloc() macro.
Change it so that we can resize arrays conveniently. Renaming similarly to slurm_xcalloc(). This name is something of my own invention - there is no direct libc equivalent that will resize allocations and ensure the contents are zero'd out, let alone for arrays, and reallocarray() itself is already non-standard. Add an extra bool argument so we can introduce try_xcalloc() while here.
Please register or sign in to comment