Path: ...!feeds.phibee-telecom.net!2.eu.feeder.erje.net!feeder.erje.net!feeds.news.ox.ac.uk!news.ox.ac.uk!earthli!nntp.terraraq.uk!.POSTED.tunnel.sfere.anjou.terraraq.org.uk!not-for-mail From: Richard Kettlewell Newsgroups: comp.os.linux.misc Subject: Re: Joy of this, Joy of that Date: Sun, 24 Nov 2024 12:46:46 +0000 Organization: terraraq NNTP server Message-ID: References: <6iKdnTQOKNh6AqD6nZ2dnZfqn_idnZ2d@earthlink.com> <20241120081039.00006d2a@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: innmantic.terraraq.uk; posting-host="tunnel.sfere.anjou.terraraq.org.uk:172.17.207.6"; logging-data="138555"; mail-complaints-to="usenet@innmantic.terraraq.uk" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Cancel-Lock: sha1:+N+BhIZwqLOpAzqBbuQA3vXc3Z8= X-Face: h[Hh-7npe<v9!1Z&W?r\c.!4DXH5PWpga"ha +r0NzP?vnz:e/knOY)PI- X-Boydie: NO Bytes: 2321 Lines: 19 Lawrence D'Oliveiro writes: > On Sat, 23 Nov 2024 10:16:46 +0000, Richard Kettlewell wrote: >> Lawrence D'Oliveiro writes: >>> >>> One thing that helps is that free(3) is idempotent: >> >> It is not. Freeing the same non-null pointer twice is a bug (and a >> common source of vulnerabilities). > > That’s not what I meant by “idempotent”, It’s what everyone else means by it. > and that particular case is easy to catch anyway, and glibc does so by > default. See . Glibc’s double free detection is heuristic, not 100% reliable. -- https://www.greenend.org.uk/rjk/