Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!texbell!attctc!kcdev!cpsolv!rhg From: rhg@cpsolv.UUCP (Richard H. Gumpertz) Newsgroups: comp.std.c Subject: Re: commom malloc/free practice breaks standard - author strikes back Message-ID: <425@cpsolv.UUCP> Date: 21 Oct 89 05:38:37 GMT References: <1989Oct16.111059.3840@anucsd.oz> <3683@altos86.Altos.COM> Reply-To: rhg@cpsolv.uucp (Richard H. Gumpertz) Organization: Computer Problem Solving, Leawood, Kansas Lines: 15 In article <3683@altos86.Altos.COM> scott@altos86.UUCP (Scott A. Rotondo) writes: >Section 4.10.3 doesn't simply state that you must be able to cast or assign >the pointer and use it; it says that you must be able to use the pointer >because it is "suitably aligned." Your hypothetical implementation only >meets the weaker of these two conditions. 1) How can one "use the pointer" without assigning or casting it? 2) The defect is not in the description of the return value from malloc. It is in the description of the parameter to free (and realloc). -- ========================================================================== | Richard H. Gumpertz rhg@cpsolv.UUCP -or- ...!uunet!amgraf!cpsolv!rhg | | Computer Problem Solving, 8905 Mohawk Lane, Leawood, Kansas 66206-1749 | ==========================================================================