]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Ecc/Check.py
BaseTools/Ecc: Remove checkpoint for STATIC modifier
[mirror_edk2.git] / BaseTools / Source / Python / Ecc / Check.py
index 6c4c90ca782115fdcefc14cbee1728fe15778b3e..c2be1b01d31956017184feafe2436275024dea48 100644 (file)
@@ -1116,7 +1116,7 @@ class Check(object):
                      """ % (Table.Table, Table.Table, Model, Model)\r
         RecordSet = Table.Exec(SqlCommand)\r
         for Record in RecordSet:     \r
-            if not EccGlobalData.gException.IsException(ErrorID, Record[1] + ':' + Record[2]):\r
+            if not EccGlobalData.gException.IsException(ErrorID, Record[2]):\r
                 EccGlobalData.gDb.TblReport.Insert(ErrorID, OtherMsg="The %s value [%s] is used more than one time" % (Name.upper(), Record[2]), BelongsToTable=Table.Table, BelongsToItem=Record[0])\r
 \r
     # Naming Convention Check\r
@@ -1223,7 +1223,10 @@ class Check(object):
             SqlCommand = """select ID, Name from %s where Model = %s""" % (FileTable, MODEL_IDENTIFIER_VARIABLE)\r
             RecordSet = EccGlobalData.gDb.TblFile.Exec(SqlCommand)\r
             for Record in RecordSet:\r
-                if not Pattern.match(Record[1]):\r
+                Var = Record[1]\r
+                if Var.startswith('CONST'):\r
+                    Var = Var[5:].lstrip()\r
+                if not Pattern.match(Var):\r
                     if not EccGlobalData.gException.IsException(ERROR_NAMING_CONVENTION_CHECK_VARIABLE_NAME, Record[1]):\r
                         EccGlobalData.gDb.TblReport.Insert(ERROR_NAMING_CONVENTION_CHECK_VARIABLE_NAME, OtherMsg="The variable name [%s] does not follow the rules" % (Record[1]), BelongsToTable=FileTable, BelongsToItem=Record[0])\r
 \r