mirror of https://github.com/acidanthera/audk.git
BaseTools: Fix FDF file parse !include file issue
when FDF file use "!include" format to include the other file, and the end line of the file not end with '\n', the include file parse error. Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
This commit is contained in:
parent
bc0d723392
commit
47a29bc707
|
@ -167,6 +167,10 @@ class IncludeFileProfile :
|
|||
fsock = open(FileName, "rb", 0)
|
||||
try:
|
||||
self.FileLinesList = fsock.readlines()
|
||||
for index, line in enumerate(self.FileLinesList):
|
||||
if not line.endswith('\n'):
|
||||
self.FileLinesList[index] += '\n'
|
||||
|
||||
finally:
|
||||
fsock.close()
|
||||
|
||||
|
|
Loading…
Reference in New Issue