From 1f6dfc6d90f3f8b02c42100da874a44d08f4e429 Mon Sep 17 00:00:00 2001 From: Justin Reichardt Date: Fri, 27 Aug 2021 15:53:58 -0500 Subject: [PATCH] Changed reallocarray to realloc Some of my other systems fail to find reallocarray --- src/rhosts.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rhosts.c b/src/rhosts.c index a447215..be091df 100644 --- a/src/rhosts.c +++ b/src/rhosts.c @@ -79,8 +79,8 @@ int parse_config(struct entry **entries){ else if ((c == '\n' || c == EOF) \ && valtyp != CONTENTTYPE_BLANK){ (*entries)[0].entrytype++; - *entries = (struct entry *)reallocarray(*entries,\ - (*j + 1), sizeof(struct entry)); + *entries = (struct entry *)realloc(*entries,\ + (*j + 1) * sizeof(struct entry)); if (*entries == NULL){return 1;} j = &(*entries)[0].entrytype; (*entries)[*j].entrytype=valtyp;