Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Lawrence D'Oliveiro Newsgroups: comp.lang.c Subject: Re: Fixing a sample from K&R book using cake static analyser Date: Mon, 24 Jun 2024 00:31:59 -0000 (UTC) Organization: A noiseless patient Spider Lines: 13 Message-ID: References: <20240623034624.135@kylheku.com> <87wmmfq4if.fsf@bsb.me.uk> <20240624012527.8bbe16b96f5bfca10feadb5c@gmail.moc> <20240624021400.75b0c38df5179dbb61b3d781@gmail.moc> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Mon, 24 Jun 2024 02:32:00 +0200 (CEST) Injection-Info: dont-email.me; posting-host="3048fea01d51f9337586ac8e02824e6c"; logging-data="624371"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+04l8qvMpnsO98YvsEQ2u3" User-Agent: Pan/0.158 (Avdiivka; ) Cancel-Lock: sha1:bsfNtLg/8G+LMTZQpH3ZOiRaEKQ= Bytes: 1584 On Mon, 24 Jun 2024 02:14:00 +0300, Anton Shepelev wrote: > Lawrence D'Oliveiro to Anton Shepelev: > >> > the failure to keep np->defn unchaged if the allocation of the new >> > defn value failed. >> >> Not sure what the point is here. > > The original funtion can replace the .defn member of an existing node > with NULL and terminate abnormally, corrupting the data structure. OK, my version doesn’t do that.