Newsgroups: comp.lang.c Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!uupsi!rlgvax!scc From: scc@rlgvax.Reston.ICL.COM (Stephen Carlson) Subject: Re: Deleting linked lists. Reply-To: scc@rlgvax.OPCR.ICL.COM (Stephen Carlson) Organization: International Computers Limited Distribution: na Date: Tue, 2 Apr 91 22:42:07 GMT Message-ID: <1991Apr2.224207.12083@rlgvax.Reston.ICL.COM> Keywords: C, C++. References: <2636@borg.cs.unc.edu> <846@saxony.pa.reuter.COM> In article <846@saxony.pa.reuter.COM> dgil@pa.reuter.COM (Dave Gillett) writes: >In <2636@borg.cs.unc.edu> warner@weiss.cs.unc.edu (Byron Warner) writes: >> free(ptr); > Even if the value of ptr is not changed by free(), you have absolutely no Since C is call-by-value, free() cannot change the value of ptr. However, free() may release space back to operating system so that a subsequent inspection of ptr will trap. -- Stephen Carlson | ICL OFFICEPOWER Center | In theory, theory and scc@rlgvax.reston.icl.com | 11490 Commerce Park Drive | practice are the same. ..!uunet!rlgvax!scc | Reston, VA 22091 |