effect of free()

Doug Gwyn gwyn at smoke.BRL.MIL
Tue Aug 15 05:40:29 AEST 1989


In article <319 at cubmol.BIO.COLUMBIA.EDU> ping at cubmol.UUCP (Shiping Zhang) writes:
>Can anyone clarify this issue for me? Thanks.

After free(), the actual storage object itself is no longer valid.
All pointers to any part of it are no longer valid.
If you attempt to continue to use those pointer values, it may appear
to work for a while on some systems, but eventually you'll get into trouble.



More information about the Comp.lang.c mailing list