From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,dc1fff2721602dfa X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit X-Received: by 10.180.82.1 with SMTP id e1mr1813841wiy.1.1360478124347; Sat, 09 Feb 2013 22:35:24 -0800 (PST) Path: g1ni2196wig.0!nntp.google.com!feeder1.cambriumusenet.nl!82.197.223.108.MISMATCH!feeder2.cambriumusenet.nl!feed.tweaknews.nl!216.196.110.144.MISMATCH!border3.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!border4.nntp.ams.giganews.com!border2.nntp.ams.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newsgate.cuhk.edu.hk!news.glorb.com!xmission!newsswitch.lcs.mit.edu!nntp.TheWorld.com!.POSTED!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Ada and string literals Date: Sat, 02 Feb 2013 09:30:37 -0500 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <4978d638-a04b-4561-85e9-cf6620265af2@googlegroups.com> <86boc63n5d.fsf@gaheris.avalon.lan> <85d2wj1nut.fsf@stephe-leake.org> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 X-Trace: pcls6.std.com 1359815437 22132 192.74.137.71 (2 Feb 2013 14:30:37 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Sat, 2 Feb 2013 14:30:37 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:tUoIZnlQuc+H9awGN7O0AAgomOU= Content-Type: text/plain; charset=us-ascii Date: 2013-02-02T09:30:37-05:00 List-Id: Stephen Leake writes: > Setting the argument to null helps avoid dangling pointers. It does. But I doubt it helps a lot, because it only detects the most obvious case, where you free X and then refer to X.all. The more subtle bug is when you free X and then refer to Y.all (or free Y). Setting X to null is no help there. - Bob