File U_27-Use-safe_xmalloc.patch of Package slurm.38904
From: Tim Wickberg <tim@schedmd.com>
Date: Wed Nov 29 15:54:54 2023 -0700
Subject: [PATCH 27/28]Use safe_xmalloc().
Patch-mainline: Upstream
Git-repo: https://github.com/SchedMD/slurm
Git-commit: 47bcf6abf7d110b1bb0546ac741dce63582f44a8
References: bsc#1218046, bsc#1218050, bsc#1218051, bsc#1218053
Signed-off-by: Egbert Eich <eich@suse.de>
---
src/common/pack.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/common/pack.c b/src/common/pack.c
index 97f6e26c84..3e29262f83 100644
--- a/src/common/pack.c
+++ b/src/common/pack.c
@@ -998,7 +998,7 @@ int unpackstr_xmalloc_escaped(char **valp, uint32_t *size_valp, Buf buffer)
return SLURM_ERROR;
/* make a buffer 2 times the size just to be safe */
- *valp = xmalloc_nz((cnt * 2) + 1);
+ safe_xmalloc(*valp, (cnt * 2) + 1);
copy = *valp;
str = &buffer->head[buffer->processed];