Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp2411434ybi; Sun, 28 Jul 2019 08:28:16 -0700 (PDT) X-Google-Smtp-Source: APXvYqyqWH5gyTFx+buTPT84+77tnbVrnpSIiItkA06RSPlxq0aSXsM2NOxG7/t+OmRUf//5/ruw X-Received: by 2002:a63:f750:: with SMTP id f16mr70708672pgk.317.1564327696013; Sun, 28 Jul 2019 08:28:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564327696; cv=none; d=google.com; s=arc-20160816; b=q9cCVFn0ZELwv0Zoz9IW+rVsiyemvMU+Khp7BZcJ0V6pcNt/dZU6qVcQTI7jC28sbT o3gvzMjo/qu9XzOlOqGObHeKI8e3VCu/0xKt+e5GobnDoSAC746wyiZNRU7s2nWy0YhC lkDZYbSaFtFyWlMVAdtVTvxG0gUTdDwwXDqy3m6v7cUTJVkOnuZuv4XO6RmCTUgxyjPB 3n7ZMlItegYhIYJOeD8hlthrNpgT2Bdug3ANNQk9w10cHq78AC8PYiiMollOYqhXYino 9yoUw/2/wS2FeDAJ00ha1uSzgHudPoKXEJTnc9FCCg3b5MjwF915XAl2qj3Ma5acc39u XBiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=YbLwTxXJgxJ6MdwPrS7V2grCWyLBsvYvQovnmMroZUg=; b=r9Y9/rpvuaMZtOAcgbr+laQVisQ9MHaVOgrie6Sg0V5pwfl3PnGefq45zxGYtMKxd3 9q+hNPCpuu5qk7KVdFZAYeejwXCFxsF42zB7d7OPC5aH/xXeT/Lsm4tADf4mcm/qv7Bl +ju5OJRFET4KRIRKBQh3Amv/tzIkWoSnm7LVq761Rg1nN8P3WI3xVIsL6FYfi7ac7Ez9 xAWIsgjbHx7UaZbFPNwFcmbWUW5mwx/1Ye5Mdt8MEEE+YnXAQikotY1kihJeCAt0Txrv Q6Yr5jClw/zhaPxBupQJLZTvT2clQBMYINS2k9xNSWYL3KsQuRd/V/VHCMqkitWQLzNy 0ilg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CJy53QQH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v15si23955450pfm.238.2019.07.28.08.28.00; Sun, 28 Jul 2019 08:28:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CJy53QQH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726108AbfG1P10 (ORCPT + 99 others); Sun, 28 Jul 2019 11:27:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:46676 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726046AbfG1P10 (ORCPT ); Sun, 28 Jul 2019 11:27:26 -0400 Received: from localhost (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2CB4D2077C; Sun, 28 Jul 2019 15:27:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564327645; bh=bSQqj81OFhTS9fr+a17fW6IivROjh1l2SgkZJuOQ7Ig=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=CJy53QQHH7HkTyXVF/sQUeuAD+Pk2nNmfgGOD0BMpldhNG3sUyV0jA66vawRIHFkw B1LuNm+6kF3qPEyjrMnSrCPfWdBQL1KEwT3AqD287PAKoYlaycmodCShjEpD2v3D3p aL22sXyXF/nSmVY8OAe6+yYhMWAy6EcwmL0ED8zQ= Date: Sun, 28 Jul 2019 11:27:24 -0400 From: Sasha Levin To: Greg Kroah-Hartman Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, Gen Zhang , Kees Cook Subject: Re: [PATCH AUTOSEL 5.2 014/171] consolemap: Fix a memory leaking bug in drivers/tty/vt/consolemap.c Message-ID: <20190728152724.GE8637@sasha-vm> References: <20190719035643.14300-1-sashal@kernel.org> <20190719035643.14300-14-sashal@kernel.org> <20190719100331.GA11778@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20190719100331.GA11778@kroah.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 19, 2019 at 07:03:31PM +0900, Greg Kroah-Hartman wrote: >On Thu, Jul 18, 2019 at 11:54:05PM -0400, Sasha Levin wrote: >> From: Gen Zhang >> >> [ Upstream commit 84ecc2f6eb1cb12e6d44818f94fa49b50f06e6ac ] >> >> In function con_insert_unipair(), when allocation for p2 and p1[n] >> fails, ENOMEM is returned, but previously allocated p1 is not freed, >> remains as leaking memory. Thus we should free p1 as well when this >> allocation fails. >> >> Signed-off-by: Gen Zhang >> Reviewed-by: Kees Cook >> Signed-off-by: Greg Kroah-Hartman >> Signed-off-by: Sasha Levin >> --- >> drivers/tty/vt/consolemap.c | 6 +++++- >> 1 file changed, 5 insertions(+), 1 deletion(-) > >No, please do not take this patch, it was reverted in commit >15b3cd8ef46a ("Revert "consolemap: Fix a memory leaking bug in >drivers/tty/vt/consolemap.c"") because it was broken. > >Please drop from all of the autosel queues. Now dropped, thanks! -- Thanks, Sasha