hi everyone,
i have another problem with realloc with a pointer to a pointer,
here is the code:
later in my code i did like this to reallocCode:typedef struct posPoolspace{ char **posList; int listSize; }posPool; typedef struct trieCDT { posPool *pool; }trieCDT; typedef struct trieCDT *Trie;
i get Segmentation Fault .. what am i doing worng??Code:char *plist=*(trie->pool->posList); plist =realloc(plist,(trie->pool->listSize+1)*sizeof(100)); strcpy(plist+trie->pool->listSize,val);



LinkBack URL
About LinkBacks




