From d09185ecbf56baeb7457f91f75375a7e41810182 Mon Sep 17 00:00:00 2001 From: Martin Pulec Date: Sat, 29 Sep 2018 21:50:50 +0200 Subject: [PATCH] Lib_common: fixed invalid pointer --- src/lib_common.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib_common.cpp b/src/lib_common.cpp index 4bd1af435..af06326f9 100644 --- a/src/lib_common.cpp +++ b/src/lib_common.cpp @@ -91,7 +91,7 @@ static void push_basename_entry(char ***binarynames, const char *bnc, size_t * t *binarynames = (char **)realloc(*binarynames, (*templates + 2)*sizeof(**binarynames)); assert(*binarynames != NULL); (*binarynames)[(*templates)++] = strdup(bn_v0); - (*binarynames)[*templates +1] = NULL; + (*binarynames)[*templates] = NULL; } free(alt_v0); }