From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.43; helo=mga05.intel.com; envelope-from=hao.a.wu@intel.com; receiver=edk2-devel@lists.01.org Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id AE4E520945B97 for ; Sun, 24 Sep 2017 18:47:50 -0700 (PDT) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga105.fm.intel.com with ESMTP; 24 Sep 2017 18:51:00 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,434,1500966000"; d="scan'208";a="903453837" Received: from shwdeopenpsi014.ccr.corp.intel.com ([10.239.9.13]) by FMSMGA003.fm.intel.com with ESMTP; 24 Sep 2017 18:50:59 -0700 From: Hao Wu To: edk2-devel@lists.01.org Cc: Hao Wu , Star Zeng Date: Mon, 25 Sep 2017 09:50:58 +0800 Message-Id: <20170925015058.17052-1-hao.a.wu@intel.com> X-Mailer: git-send-email 2.12.0.windows.1 Subject: [PATCH] MdeModulePkg/DxeCore: Add check to ensure no possible NULL ptr deref X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2017 01:47:50 -0000 Cc: Star Zeng Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu --- MdeModulePkg/Core/Dxe/Hand/Handle.c | 1 + 1 file changed, 1 insertion(+) diff --git a/MdeModulePkg/Core/Dxe/Hand/Handle.c b/MdeModulePkg/Core/Dxe/Hand/Handle.c index 3ed187b279..2db441725c 100644 --- a/MdeModulePkg/Core/Dxe/Hand/Handle.c +++ b/MdeModulePkg/Core/Dxe/Hand/Handle.c @@ -1178,6 +1178,7 @@ Done: // EFI_ALREADY_STARTED is not an error for bus driver. // Return the corresponding protocol interface. // + ASSERT (Prot != NULL); *Interface = Prot->Interface; } else if (Status == EFI_UNSUPPORTED) { // -- 2.12.0.windows.1