Remove redundant tmp check (#76154)
authorRose <83477269+AtariDreams@users.noreply.github.com>
Sun, 25 Sep 2022 21:58:38 +0000 (17:58 -0400)
committerGitHub <noreply@github.com>
Sun, 25 Sep 2022 21:58:38 +0000 (14:58 -0700)
The function has an early return if tmp is ever null, so there is no need to have this check here.

src/coreclr/ilasm/asmman.cpp

index 1a7118e..a370656 100644 (file)
@@ -181,7 +181,7 @@ void    AsmMan::AddFile(_In_ __nullterminated char* szName, DWORD dwAttr, BinStr
         tmp->tkTok = TokenFromRid(m_FileLst.COUNT(),mdtFile);
     }
     pAsm->m_tkCurrentCVOwner = 0;
-    if(tmp) pAsm->m_pCustomDescrList = &(tmp->m_CustomDescrList);
+    pAsm->m_pCustomDescrList = &(tmp->m_CustomDescrList);
 }
 //==============================================================================================================