]> git.tuebingen.mpg.de Git - paraslash.git/blobdiff - interactive.c
string: Introduce arr_realloc() and check for integer overflow.
[paraslash.git] / interactive.c
index ee4878fb918218c4ce53b6c227132b4b45afd203..98882ce6d772c162be24ea481daf8f847eb34d5c 100644 (file)
@@ -656,8 +656,8 @@ int i9e_extract_completions(const char *word, char **string_list,
                match_count++;
                if (match_count >= matches_len) {
                        matches_len *= 2;
-                       matches = para_realloc(matches,
-                               matches_len * sizeof(char *));
+                       matches = arr_realloc(matches, matches_len,
+                               sizeof(char *));
                }
                matches[match_count - 1] = para_strdup(*p);
        }