From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12237 invoked by alias); 4 May 2015 14:38:28 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 35030 Received: (qmail 10725 invoked from network); 4 May 2015 14:38:25 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=X8jkpiJh2IO68orTNNbgrOgMVlsSNJqsgwgWLov3YY0=; b=tiULdAWOio7VPaVwL4bNXV/fct3tjZQ/vSeD+h2fh91BZeMflHRfEa/yFznidIE1PD jg6va+cphh3KLGWtHII5aQXiLT0ulvTCwqRSJyQ/HwfJz6cshPZCDLV2+LbSP84YwSP/ 9OI8a8UnxWK5acyV3rZmsXQWWULa5dVY3Uw+CE2mdXTnQIw1TSDkZg8VJkPJMlew5Fm9 PVUsyt2E2C1aowB9aeWApb5774LE3Bbgi0BlAMkFiY2wmkynxvj67RLNXOkJP6iMVGqb 5S9/POmIeogaJw8/5fLE5WIZKnfwavWW5YLZSzXYXYUyp8Gj2K75MtEyN/yQZytQCZ61 8mKw== MIME-Version: 1.0 X-Received: by 10.107.163.79 with SMTP id m76mr28488816ioe.85.1430750302465; Mon, 04 May 2015 07:38:22 -0700 (PDT) In-Reply-To: References: Date: Mon, 4 May 2015 16:38:22 +0200 Message-ID: Subject: Re: Double free with latest updates From: Mikael Magnusson To: Vin Shelton Cc: "Zsh Hackers' List" Content-Type: text/plain; charset=UTF-8 On Mon, May 4, 2015 at 1:20 PM, Vin Shelton wrote: > The most recent changes to builtin.c result in a double free in running the > test suite. > > I have more details if you need them. > > - Vin > > zsh > remote: Counting objects: 9, done. > remote: Compressing objects: 100% (5/5), done. > remote: Total 5 (delta 4), reused 0 (delta 0) > Unpacking objects: 100% (5/5), done. > From git://zsh.git.sf.net/gitroot/zsh/zsh > 5b00bfe..1e6fb1a master -> origin/master > Updating 5b00bfe..1e6fb1a > Fast-forward > ChangeLog | 4 ++++ > Src/builtin.c | 7 ++++--- > 2 files changed, 8 insertions(+), 3 deletions(-) > > Building zsh > /opt/src/zsh-2015-05-04 > cd . && ./.preconfig > Configuring zsh-2015-05-04 for installation prefix /opt/zsh-2015-05-04. > Building zsh...done. > Running tests...% > print ten ten nine one print > print print one two three four five six seven eight nine ten one two > print mystery sequence > print one > print two > print mystery sequence > print metaphor\? shmetaphor! > print metaphor! > print -l metophor, Molochi, > echo $(echo foo bar) again > echo more $( echo $(echo foo bar) again ) > done. > *** Error in `zsh': double free or corruption (out): 0x00007fff694af880 *** > Doesn't happen here with or without --enable-zsh-{mem,debug}. Valgrind also didn't complain at all. Enable the MALLOC_CHECK_ flag that enables backtrace on double free and see if it says anything useful. "If MALLOC_CHECK_ is set to 0, any detected heap corruption is silently ignored; if set to 1, a diagnostic is printed on stderr; if set to 2, abort is called immediately." -- Mikael Magnusson