Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5935295ybi; Wed, 12 Jun 2019 11:00:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqwmFQLbmN66kCcOw75J2soYArsEJEmq2neIt9yp/cgoBuMMeaZW/cqxdTvkAPk5fJey908J X-Received: by 2002:a62:6083:: with SMTP id u125mr10918652pfb.208.1560362402629; Wed, 12 Jun 2019 11:00:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560362402; cv=none; d=google.com; s=arc-20160816; b=UreaXh0sffgz3Bwu5T6qRFGmTYm2hmSHz7NdwHAjGZcE/5u9WFNUdlZ3gZs6GFan41 +ENuRWA+L/8Li8QSMGGrf4gJCuvBhqrMfE2ZnwqCfH7rbN8Q5V8+7F61ncapKKw9fNFn vLsKS1PQ2lNCVSTvf54pwLySjrbxgbE8ReH5FstBdi3ujDUMOTuMCtKyrVbPaifeAIqS bhkoY8tgrUb4J/xGkZeXhRkUpWedfLh6MaD39LNxji5IuxXFX5KqLmhbHS8Vi3Nw6viU /OEPj0cENvNbxWpM0yDE0pC0e8om1Fbx1xD3dm2QSKL1aZMj3pSPVgcNz1zJp1Tf27L8 qyCQ== 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=BFnDjbb0VsujkwxWYQXWJs7gO/uCQ3U0L3dc3qa8CNc=; b=ToedD5kLF0PldWaqeIZ9LQ7//jF5yBuq/nR6MNVjBnq4M8zXyI8+Tsc/eocMDVn0wt JobQ9hTv1sep6vtxg7udW+rGCczMOcDW3QTdncZQmu+fOHvpjDFHkyh7B0ITY6Nf7MzT jZtQvQRPLHJJWcyxWoeMPlDR5H8uiA2CNnEa7ESMUWaAHUWKpo0KeXchYav3kpx01MC2 2WPpv0QYYhC1JWdUHzv/xpy7kEj0PWh2cIPworoQvwSlhz24qt3v7OrfGVd/MscF/h8T XALXre/Eg8yxWa2MpJZGIdgD51htU6wYhy3Vnqa6mjsPS2N2kYFa5IckC+bU+LiNte4O JQqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BX9y7BKH; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m11si436864pjl.64.2019.06.12.10.59.47; Wed, 12 Jun 2019 11:00:02 -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=BX9y7BKH; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731742AbfFLNin (ORCPT + 99 others); Wed, 12 Jun 2019 09:38:43 -0400 Received: from mail.kernel.org ([198.145.29.99]:57256 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726822AbfFLNim (ORCPT ); Wed, 12 Jun 2019 09:38:42 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 A8092208CA; Wed, 12 Jun 2019 13:38:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1560346722; bh=zTTjXk6HPFKtrXGF56kPymN9VxXefIYOXj73DCi/m64=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=BX9y7BKHsJp8BM8+tDxmPbBtpXd/P6njt64f1QZYq2tv//bttARdhDk/n0n1uNXQ0 yPme7uNodBGe7RnUNUO8iKHVTmgcZNJDU4uUyAOOAMuo3jktacyzIhJprKiP4oftae b4F9yv4nF1UinRGsle9GoTXcj1a6b9Vf4zONYrrg= Date: Wed, 12 Jun 2019 15:38:38 +0200 From: Greg KH To: Gen Zhang Cc: nico@fluxnic.net, kilobyte@angband.pl, textshell@uchuujin.de, mpatocka@redhat.com, daniel.vetter@ffwll.ch, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] vt: fix a missing-check bug in con_init() Message-ID: <20190612133838.GA7748@kroah.com> References: <20190612131506.GA3526@zhanggen-UX430UQ> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190612131506.GA3526@zhanggen-UX430UQ> User-Agent: Mutt/1.12.0 (2019-05-25) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 12, 2019 at 09:15:06PM +0800, Gen Zhang wrote: > In function con_init(), the pointer variable vc_cons[currcons].d, vc and > vc->vc_screenbuf is allocated by kzalloc(). However, kzalloc() returns > NULL when fails. Therefore, we should check the return value and handle > the error. > > Signed-off-by: Gen Zhang > --- What changed from v1, v2, and v3? That always goes below the --- line. v5 please. thanks, greg k-h