From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 27579C32772 for ; Tue, 23 Aug 2022 10:05:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351963AbiHWKFP (ORCPT ); Tue, 23 Aug 2022 06:05:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58976 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351935AbiHWKA4 (ORCPT ); Tue, 23 Aug 2022 06:00:56 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 516D462F7; Tue, 23 Aug 2022 01:48:26 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 8BA90B81C35; Tue, 23 Aug 2022 08:48:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F0641C433C1; Tue, 23 Aug 2022 08:48:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661244503; bh=Rb8RqMWonuLosEt81hl+n3DDIYofEdVxfe5kXGS+gVU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pLww8JaNb8wYNR290wJQgw0n1z0ZepjMKdsbAW+EEgjU+O1BbpvcUDhcGW4V8Z/BB EK2luMmAxVQ7iBHkRaLv7lJyYwc/lAQZ5b/Mu72QToX2HHbsWam1DQ7pl9kyw/CQR0 6DMWYbvMeOb2cnb8r7RjtAf6lANIZ6tYo2ZqSfHI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yan Lei , Konstantin Komarov Subject: [PATCH 5.15 103/244] fs/ntfs3: Fix using uninitialized value n when calling indx_read Date: Tue, 23 Aug 2022 10:24:22 +0200 Message-Id: <20220823080102.463502199@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220823080059.091088642@linuxfoundation.org> References: <20220823080059.091088642@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yan Lei commit ae5a4e46916fc307288227b64c1d062352eb93b7 upstream. This value is checked in indx_read, so it must be initialized Fixes: 82cae269cfa9 ("fs/ntfs3: Add initialization of super block") Signed-off-by: Yan Lei Signed-off-by: Konstantin Komarov Signed-off-by: Greg Kroah-Hartman --- fs/ntfs3/index.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/ntfs3/index.c +++ b/fs/ntfs3/index.c @@ -1994,7 +1994,7 @@ static int indx_free_children(struct ntf const struct NTFS_DE *e, bool trim) { int err; - struct indx_node *n; + struct indx_node *n = NULL; struct INDEX_HDR *hdr; CLST vbn = de_get_vbn(e); size_t i;