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.120; helo=mga04.intel.com; envelope-from=yonghong.zhu@intel.com; receiver=edk2-devel@lists.01.org Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) (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 BCFF1203B8CC9 for ; Thu, 10 May 2018 17:16:01 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 May 2018 17:16:01 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,387,1520924400"; d="scan'208";a="40048511" Received: from fmsmsx103.amr.corp.intel.com ([10.18.124.201]) by orsmga007.jf.intel.com with ESMTP; 10 May 2018 17:16:00 -0700 Received: from fmsmsx113.amr.corp.intel.com (10.18.116.7) by FMSMSX103.amr.corp.intel.com (10.18.124.201) with Microsoft SMTP Server (TLS) id 14.3.319.2; Thu, 10 May 2018 17:16:00 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by FMSMSX113.amr.corp.intel.com (10.18.116.7) with Microsoft SMTP Server (TLS) id 14.3.319.2; Thu, 10 May 2018 17:16:00 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.210]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.40]) with mapi id 14.03.0319.002; Fri, 11 May 2018 08:15:58 +0800 From: "Zhu, Yonghong" To: "Lin, Derek (HPS UEFI Dev)" , "edk2-devel@lists.01.org" Thread-Topic: [PATCH] BaseTools: Fix python error with --genfds-multi-thread. Thread-Index: AQHT53QZ37rF4FhwF0OcQZLWyKDU3KQnGY6ggAKRo3A= Date: Fri, 11 May 2018 00:15:58 +0000 Message-ID: References: <20180509085932.1032-1-derek.lin2@hpe.com> In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] BaseTools: Fix python error with --genfds-multi-thread. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 May 2018 00:16:01 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Yonghong Zhu =20 Best Regards, Zhu Yonghong -----Original Message----- From: Lin, Derek (HPS UEFI Dev) [mailto:derek.lin2@hpe.com]=20 Sent: Wednesday, May 09, 2018 5:03 PM To: edk2-devel@lists.01.org Cc: Zhu, Yonghong ; Lin, Derek (HPS UEFI Dev) Subject: [PATCH] BaseTools: Fix python error with --genfds-multi-thread. When self.Alignment is None, it ran into python error since there is no strip() in None. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Derek Lin --- BaseTools/Source/Python/GenFds/GuidSection.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/BaseTools/Source/Python/GenFds/GuidSection.py b/BaseTools/Sour= ce/Python/GenFds/GuidSection.py index 1105689e0d..6cadff0bd2 100644 --- a/BaseTools/Source/Python/GenFds/GuidSection.py +++ b/BaseTools/Source/Python/GenFds/GuidSection.py @@ -2,7 +2,7 @@ # process GUIDed section generation # # Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.
= -# +# Copyright (c) 2018, Hewlett Packard Enterprise Development, L.P.
# This program and the accompanying materials # are licensed and made a= vailable under the terms and conditions of the BSD License # which accomp= anies this distribution. The full text of the license may be found at @@ -= 273,7 +273,7 @@ class GuidSection(GuidSectionClassObject) : self.Alignment =3D None self.IncludeFvSection =3D False self.ProcessRequired =3D "TRUE" - if IsMakefile and self.Alignment.strip() =3D=3D '0': + if IsMakefile and self.Alignment is not None and self.Alignmen= t.strip() =3D=3D '0': self.Alignment =3D '1' return OutputFileList, self.Alignment =20 -- 2.15.1.windows.2