free()

Mohsen Pahlevanzadeh mohsen@pahlevanzadeh.org
Sun Sep 27 08:48:00 GMT 2009


Dear all,
We are working on C code (not ++),So we must use free instead delete.
I have following code:
/////////////////////////////////
        struct linked_list *p;
	p->src="10.0.0.1";
        free(p);
        printf ("%s",p->srcip);
/////////I see in my output 10.0.0.1 
My question: i drop p pinter, but see it's value, how i kill p with its
value?

Yours,
Mohsen




More information about the Gcc-help mailing list