Freeing Data Section Memory
If your program initializes static and global variables, it places them in your executable’s data section. Your program cannot free this memory.
The following program tries to free a variable in this section:
static int data_var = 9;
int main (int argc, char *argv[])
{
void *addr = (void *) (&data_var);
/* Error: adress in data section */
free(addr);
return 0;
}