]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: Fix bug for VOID* DynamicDefault Pcd use Flexible format
authorYonghong Zhu <yonghong.zhu@intel.com>
Thu, 15 Mar 2018 11:40:18 +0000 (19:40 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Sun, 18 Mar 2018 07:01:07 +0000 (15:01 +0800)
define a flexible pcd format in Dyanmic/DynamicExDefault section,
it cause build error.
[PcdsDynamicExDefault.common.DEFAULT]
  pcdToken.Name|{GUID("11111111-2222-42eb-b5eb-fef31d207cb4")}

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
BaseTools/Source/Python/Common/Misc.py

index 2086b4c69d17e1d167722fc616d7f0de3f8f24fd..7d44fdcf8ba73b42107299e65e36a7b4379659fb 100644 (file)
@@ -1720,14 +1720,6 @@ def AnalyzeDscPcd(Setting, PcdType, DataType=''):
             Type = DataType\r
         if len(FieldList) > 2:\r
             Size = FieldList[2]\r
-        else:\r
-            if Type == 'VOID*':\r
-                if Value.startswith("L"):\r
-                    Size = str((len(Value)- 3 + 1) * 2)\r
-                elif Value.startswith("{"):\r
-                    Size = str(len(Value.split(",")))\r
-                else:\r
-                    Size = str(len(Value) -2 + 1 )\r
         if DataType == "":\r
             IsValid = (len(FieldList) <= 1)\r
         else:\r