From: Michael Tremer Date: Fri, 3 Jan 2025 09:30:42 +0000 (+0000) Subject: strings: Help the compiler to understand what array we mean X-Git-Tag: 0.9.30~565 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=30b13721567d54c1c411270bb669fe2a603bc56b;p=pakfire.git strings: Help the compiler to understand what array we mean Signed-off-by: Michael Tremer --- diff --git a/src/pakfire/string.h b/src/pakfire/string.h index bdc5d06c0..47c2f373e 100644 --- a/src/pakfire/string.h +++ b/src/pakfire/string.h @@ -120,12 +120,12 @@ inline int pakfire_strings_append(char*** array, const char* s) { return -errno; // Copy the string - char* p = *array[length++] = strdup(s); + char* p = (*array)[length++] = strdup(s); if (!p) return -errno; // Terminate the array - *array[length] = NULL; + (*array)[length] = NULL; // Return the total length of the array return length;