|
From: <yi...@us...> - 2011-09-30 03:28:14
|
Revision: 2337
http://edk2-buildtools.svn.sourceforge.net/edk2-buildtools/?rev=2337&view=rev
Author: yingke
Date: 2011-09-30 03:28:08 +0000 (Fri, 30 Sep 2011)
Log Message:
-----------
Fix a bug to report correct line number and line content when region type keyword is not expected.
Signed-off-by: yingke
Reviewed-by: jsu1, gikidy
Modified Paths:
--------------
trunk/BaseTools/Source/Python/GenFds/FdfParser.py
Modified: trunk/BaseTools/Source/Python/GenFds/FdfParser.py
===================================================================
--- trunk/BaseTools/Source/Python/GenFds/FdfParser.py 2011-09-30 03:27:02 UTC (rev 2336)
+++ trunk/BaseTools/Source/Python/GenFds/FdfParser.py 2011-09-30 03:28:08 UTC (rev 2337)
@@ -1610,9 +1610,13 @@
self.__UndoToken()
self.__GetRegionFileType( RegionObj)
- else:
+ elif self.__Token == "DATA":
self.__UndoToken()
self.__GetRegionDataType( RegionObj)
+ else:
+ raise Warning("A valid region type was not found. "
+ "Valid types are [SET, FV, CAPSULE, FILE, DATA]. This error occurred",
+ self.FileName, self.CurrentLineNumber)
return True
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|