The lib/cgraph/alloc.h wrappers are similar to the older lib/common/memory.h
wrappers except (1) they are header-only and (2) they live in a directory
(cgraph) that is at the root of the dependency tree. The long term plan is to
replace all use of lib/common/memory.h with lib/cgraph/alloc.h.
}
static void attach_edge_label_coordinates(int dim, SparseMatrix A, int n_edge_label_nodes, int *edge_label_nodes, double *x, double *x2){
- int *mask;
int i, ii, j, k;
int nnodes = 0;
double len;
- mask = MALLOC(sizeof(int)*A->m);
+ int *mask = gv_calloc(A->m, sizeof(int));
for (i = 0; i < A->m; i++) mask[i] = 1;
for (i = 0; i < n_edge_label_nodes; i++) {