Hi
I have code which looks like this
ABC_STRUCT abc[50];
unsigned int j=0;
for (i=0;i< x;i++) {
char* sub = (char *) malloc (somesize);
strcpy(sub,some source);
abc[j].data= (unsigned char*) sub;
abc[j].len= strlen(sub);
...........
j++
}
for(i=0;i<=j-1;i++)
{
free((POINTER)abc[i].data
}
I just wanted to make sure that the above code is freeing up the memory properly and there are no memory leaks
Thanks in advance