]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/GenFds/Section.py
BaseTools: Remove equality operator with None
[mirror_edk2.git] / BaseTools / Source / Python / GenFds / Section.py
index 463faa378165084168b42db41b413a2ac642e851..5e0b4bee7d1c509f8f81bedca7b9ee5f3786a1d6 100644 (file)
@@ -116,17 +116,17 @@ class Section (SectionClassObject):
         else :\r
             IsSect = False\r
 \r
-        if FileExtension != None:\r
+        if FileExtension is not None:\r
             Suffix = FileExtension\r
         elif IsSect :\r
             Suffix = Section.SectionType.get(FileType)\r
         else:\r
             Suffix = Section.BinFileType.get(FileType)\r
-        if FfsInf == None:\r
+        if FfsInf is None:\r
             EdkLogger.error("GenFds", GENFDS_ERROR, 'Inf File does not exist!')\r
 \r
         FileList = []\r
-        if FileType != None:\r
+        if FileType is not None:\r
             for File in FfsInf.BinFileList:\r
                 if File.Arch == "COMMON" or FfsInf.CurrentArch == File.Arch:\r
                     if File.Type == FileType or (int(FfsInf.PiSpecVersion, 16) >= 0x0001000A \\r
@@ -141,7 +141,7 @@ class Section (SectionClassObject):
                 else:\r
                     GenFdsGlobalVariable.InfLogger ("\nCurrent ARCH \'%s\' of File %s is not in the Support Arch Scope of %s specified by INF %s in FDF" %(FfsInf.CurrentArch, File.File, File.Arch, FfsInf.InfFileName))\r
 \r
-        if (not IsMakefile and Suffix != None and os.path.exists(FfsInf.EfiOutputPath)) or (IsMakefile and Suffix != None):\r
+        if (not IsMakefile and Suffix is not None and os.path.exists(FfsInf.EfiOutputPath)) or (IsMakefile and Suffix is not None):\r
             #\r
             # Get Makefile path and time stamp\r
             #\r