From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22888 invoked by alias); 14 May 2014 09:30:50 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 22865 invoked by uid 89); 14 May 2014 09:30:50 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.0 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mail-gw2-out.broadcom.com Received: from mail-gw2-out.broadcom.com (HELO mail-gw2-out.broadcom.com) (216.31.210.63) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 14 May 2014 09:30:49 +0000 Received: from irvexchcas08.broadcom.com (HELO IRVEXCHCAS08.corp.ad.broadcom.com) ([10.9.208.57]) by mail-gw2-out.broadcom.com with ESMTP; 14 May 2014 02:58:16 -0700 Received: from IRVEXCHSMTP2.corp.ad.broadcom.com (10.9.207.52) by IRVEXCHCAS08.corp.ad.broadcom.com (10.9.208.57) with Microsoft SMTP Server (TLS) id 14.3.174.1; Wed, 14 May 2014 02:30:47 -0700 Received: from mail-irva-13.broadcom.com (10.10.10.20) by IRVEXCHSMTP2.corp.ad.broadcom.com (10.9.207.52) with Microsoft SMTP Server id 14.3.174.1; Wed, 14 May 2014 02:30:47 -0700 Received: from [10.177.72.87] (unknown [10.177.72.87]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id 973319FA84; Wed, 14 May 2014 02:30:24 -0700 (PDT) Message-ID: <537337AF.3020806@broadcom.com> Date: Wed, 14 May 2014 09:30:00 -0000 From: Andrew Burgess User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: Gary Benson , Ian Lance Taylor CC: gcc-patches , Jason Merrill , Subject: Re: [PATCH] cplus-demangler, free resource after a failed call to gnu_special. References: <1399646123-9960-1-git-send-email-aburgess@broadcom.com> <536E7A72.1040203@broadcom.com> <20140514090125.GA4974@blade.nx> In-Reply-To: <20140514090125.GA4974@blade.nx> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2014-05/txt/msg01058.txt.bz2 On 14/05/2014 10:01 AM, Gary Benson wrote: > Ian Lance Taylor wrote: >> Andrew Burgess wrote: >>> On 09/05/2014 9:53 PM, Ian Lance Taylor wrote: >>>> Andrew Burgess wrote: >>>>> if ((AUTO_DEMANGLING || GNU_DEMANGLING)) >>>>> { >>>>> success = gnu_special (work, &mangled, &decl); >>>>> + if (!success) >>>>> + { >>>>> + delete_work_stuff (work); >>>>> + string_delete (&decl); >>>>> + } >>>> >> >> This patch is OK. > > Andrew, would you like me to commit this? Yes please. Thanks, Andrew