Currently when parse VFR files to get the struct info,
BOOLEAN type struct is ignored, which caused offset errors.
This patch fixed these bugs.
Cc: Bob Feng <bob.c.feng@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Signed-off-by: Yuwei Chen <yuwei.chen@intel.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
Reviewed-by: Bob Feng <bob.c.feng@intel.com>
line.append(struct)\r
unparse.append(line)\r
else:\r
- if uint not in ['UINT8', 'UINT16', 'UINT32', 'UINT64']:\r
+ if uint not in ['UINT8', 'UINT16', 'UINT32', 'UINT64', 'BOOLEAN']:\r
line = [offset, t_name, 0, uint]\r
line.append(struct)\r
unparse.append(line)\r
for i in List:\r
for j in i:\r
tmp = j.split("|")\r
- if (('L"' in j) and ("[" in j)) or (tmp[1].strip() == '{0x0, 0x0}'):\r
+ if (('L"' in j) and ("[" in j)) or (tmp[1].split("#")[0].strip() == '{0x0, 0x0}'):\r
tmp[0] = tmp[0][:tmp[0].index('[')]\r
List[List.index(i)][i.index(j)] = "|".join(tmp)\r
else:\r