From 9508d0fa4fb2cd2ff03604bc3b1b1abf8f69ccb6 Mon Sep 17 00:00:00 2001 From: lgao4 Date: Fri, 16 Dec 2011 08:52:13 +0000 Subject: Sync BaseTool trunk (version r2474) into EDKII BaseTools. Signed-off-by: lgao4 Reviewed-by: gikidy git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12883 6f19259b-4bc3-4df7-8a09-765794883524 --- .../Source/Python/UPT/Library/ParserValidate.py | 2 +- BaseTools/Source/Python/UPT/Library/String.py | 29 ---------------------- 2 files changed, 1 insertion(+), 30 deletions(-) (limited to 'BaseTools/Source/Python/UPT/Library') diff --git a/BaseTools/Source/Python/UPT/Library/ParserValidate.py b/BaseTools/Source/Python/UPT/Library/ParserValidate.py index 8efb56a61a..860fb4f1dc 100644 --- a/BaseTools/Source/Python/UPT/Library/ParserValidate.py +++ b/BaseTools/Source/Python/UPT/Library/ParserValidate.py @@ -286,7 +286,7 @@ def IsValidInstallPath(Path): if os.path.isabs(Path): return False else: - if Path[1:2] == ':' or Path.find('\\') >=0: + if Path[1:2] == ':': return False if os.path.isabs(Path): return False diff --git a/BaseTools/Source/Python/UPT/Library/String.py b/BaseTools/Source/Python/UPT/Library/String.py index 526b2e66b4..2c5853ca93 100644 --- a/BaseTools/Source/Python/UPT/Library/String.py +++ b/BaseTools/Source/Python/UPT/Library/String.py @@ -643,35 +643,6 @@ def ConvertToSqlString(StringList): def ConvertToSqlString2(String): return String.replace("'", "''") -## RemoveBlockComment -# -# Remove comment block -# -# @param Lines: Block Comment Lines -# -def RemoveBlockComment(Lines): - IsFindBlockComment = False - ReservedLine = '' - NewLines = [] - - for Line in Lines: - Line = Line.strip() - # - # Remove comment block - # - if Line.find(DataType.TAB_COMMENT_EDK1_START) > -1: - ReservedLine = GetSplitList(Line, DataType.TAB_COMMENT_EDK1_START, 1)[0] - IsFindBlockComment = True - if Line.find(DataType.TAB_COMMENT_EDK1_END) > -1: - Line = ReservedLine + GetSplitList(Line, DataType.TAB_COMMENT_EDK1_END, 1)[1] - ReservedLine = '' - IsFindBlockComment = False - if IsFindBlockComment: - NewLines.append('') - continue - NewLines.append(Line) - return NewLines - ## GetStringOfList # # Get String of a List -- cgit v1.2.3