[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[igraph] error.c:125: failed assertion `no<100'
From: |
igraph . x . flushy |
Subject: |
[igraph] error.c:125: failed assertion `no<100' |
Date: |
Tue, 16 Jun 2009 19:08:15 +0200 |
Hi,
I'm currently building my own interface to igraph.
But after building some 100 Graphs it crashes with
error.c:125: failed assertion `no<100'
I probably forget to clean something but I have no idea what?
Functions for creating and destroying the graphs are included.
The only thing special is that I store for every node a name.
Or can I figure somehow out the size of the stack (or increase it).
Therefor I defined my own struct:
typedef struct {
igraph_t * graph;
igraph_trie_t * names;
} yap_igraph_t;
Construction code:
yap_igraph_t * ygraph=malloc(sizeof(yap_igraph_t));
ygraph->graph=malloc(sizeof(igraph_t));
igraph_t * graph= ygraph->graph;
//printf("%p \n ",ygraph);
igraph_vector_t * v1 = malloc(sizeof(igraph_vector_t));
igraph_vector_init(v1, 0);
igraph_create(graph, v1, 0, IGRAPH_UNDIRECTED);
igraph_vector_destroy(v1);
ygraph->names=malloc(sizeof(igraph_trie_t));
//I also do not sure, why I need the next to lines both. But
without it doesnt work
igraph_trie_init(ygraph->names,0);
IGRAPH_TRIE_INIT_FINALLY(ygraph->names,TRUE);
Destruction code:
igraph_trie_destroy(ygraph->names);
igraph_destroy(ygraph->graph);
igraph_free(ygraph->names);
igraph_free(ygraph->graph);
free(ygraph);
Thanks in advance
- [igraph] error.c:125: failed assertion `no<100',
igraph . x . flushy <=