]> granicus.if.org Git - graphviz/commitdiff
agglomerative_bundling.c: explicitly cast the results of 'realloc'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 15 Jan 2022 21:12:31 +0000 (13:12 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 16 Jan 2022 18:51:42 +0000 (10:51 -0800)
This has no effect in C, but an upcoming change will move this code to C++ where
this is required.

Gitlab: #2154

lib/mingle/agglomerative_bundling.c

index 5e4244b46901a18fb4a6169ed2b45805df95c9e3..a6382cc205716f09044086ae961c1285738d7c33 100644 (file)
@@ -384,7 +384,7 @@ static pedge* agglomerative_ink_bundling_internal(int dim, SparseMatrix A, pedge
                                                 improved later */
            e = edges[jj] = pedge_double(edges[jj]);
 
-           e->wgts = REALLOC(e->wgts, sizeof(double)*4);       
+           e->wgts = (double*)REALLOC(e->wgts, sizeof(double)*4);      
            e->x[1*dim] = meet1.x;
            e->x[1*dim+1] = meet1.y;
            e->x[2*dim] = meet2.x;