From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.31; helo=mga06.intel.com; envelope-from=hao.a.wu@intel.com; receiver=edk2-devel@lists.01.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (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 30F162217CE58 for ; Sun, 7 Jan 2018 21:25:38 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Jan 2018 21:30:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.46,329,1511856000"; d="scan'208";a="8276693" Received: from shwdeopenpsi014.ccr.corp.intel.com ([10.239.9.10]) by fmsmga002.fm.intel.com with ESMTP; 07 Jan 2018 21:30:46 -0800 From: Hao Wu To: edk2-devel@lists.01.org Cc: Hao Wu , Ruiyu Ni , Yonghong Zhu , Liming Gao Date: Mon, 8 Jan 2018 13:30:39 +0800 Message-Id: <20180108053044.11788-1-hao.a.wu@intel.com> X-Mailer: git-send-email 2.12.0.windows.1 Subject: [PATCH 0/5] BaseTools/Common & DevicePath: Code refinements X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Jan 2018 05:25:39 -0000 The series refines the C/C++ source codes within BaseTools/C/Source/Common/ and BaseTools/Source/C/DevicePath/ for the below catagories: * Resolve possible resource/memory leaks * Resolve possible NULL pointer dereferences Cc: Ruiyu Ni Cc: Yonghong Zhu Cc: Liming Gao Hao Wu (5): BaseTools/C/Common: Fix code to be more readable BaseTools/C/Common: Fix potential memory leak BaseTools/DevicePath: Fix potential memory leak BaseTools/C/Common: Fix potential null pointer dereference BaseTools/DevicePath: Fix potential null pointer dereference BaseTools/Source/C/Common/CommonLib.c | 2 +- BaseTools/Source/C/Common/PcdValueCommon.c | 10 ++++++++++ BaseTools/Source/C/DevicePath/DevicePath.c | 6 ++++++ BaseTools/Source/C/DevicePath/DevicePathFromText.c | 11 +++++++++++ 4 files changed, 28 insertions(+), 1 deletion(-) -- 2.12.0.windows.1