From: Matthew Fernandez Date: Sun, 1 May 2022 23:20:31 +0000 (-0700) Subject: gvmap: fix pointer-vs-int confusion in calling 'gv_recalloc' X-Git-Tag: 4.0.0~26^2~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2cde5c48434503beecda23711f5a55c9ae4ffdc8;p=graphviz gvmap: fix pointer-vs-int confusion in calling 'gv_recalloc' This was a typo in 0e53497fae6e05a59c31b7f124ddd1166901759f. It seemingly went unnoticed amid the torrent of warnings the Autotools build emits. I only picked this up when enabling this code in the CMake build system that compiles with -Werror in CI. --- diff --git a/cmd/gvmap/make_map.c b/cmd/gvmap/make_map.c index 98879a5cc..b5e5540f9 100644 --- a/cmd/gvmap/make_map.c +++ b/cmd/gvmap/make_map.c @@ -1297,7 +1297,7 @@ static void add_point(int *n, int igrp, double **x, int *nmax, double point[], i int old_nmax = *nmax; *nmax = MAX((int) 0.2*(*n), 20) + *n; *x = gv_recalloc(*x, 2 * old_nmax, 2 * *nmax, sizeof(double)); - *groups = gv_recalloc(*groups, old_nmax, nmax, sizeof(int)); + *groups = gv_recalloc(*groups, old_nmax, *nmax, sizeof(int)); } (*x)[(*n)*2] = point[0];