mirror of
https://bitbucket.org/theswgsource/src-1.2.git
synced 2026-07-31 01:15:48 -04:00
fix some cppcheck detected issues
This commit is contained in:
@@ -323,26 +323,6 @@ void DataLint::report()
|
||||
writeError(assetErrorFileAllWarning, *warningListIter, totalErrorCountAllWarning);
|
||||
}
|
||||
}
|
||||
|
||||
if (assetErrorFileAll) { fclose(assetErrorFileAll); }
|
||||
if (assetErrorFileAllFatal) { fclose(assetErrorFileAllFatal); }
|
||||
if (assetErrorFileAllWarning) { fclose(assetErrorFileAllWarning); }
|
||||
if (assetErrorFileObjectTemplate) { fclose(assetErrorFileObjectTemplate); }
|
||||
|
||||
if (m_mode == M_client)
|
||||
{
|
||||
if (assetErrorFileAppearance) { fclose(assetErrorFileAppearance); }
|
||||
if (assetErrorFileArrangementDescriptor) { fclose(assetErrorFileArrangementDescriptor); }
|
||||
if (assetErrorFileLocalizedStringTable) { fclose(assetErrorFileLocalizedStringTable); }
|
||||
if (assetErrorFilePortalProperty) { fclose(assetErrorFilePortalProperty); }
|
||||
if (assetErrorFileShaderTemplate) { fclose(assetErrorFileShaderTemplate); }
|
||||
if (assetErrorFileSkyBox) { fclose(assetErrorFileSkyBox); }
|
||||
if (assetErrorFileSlotDescriptor) { fclose(assetErrorFileSlotDescriptor); }
|
||||
if (assetErrorFileSoundTemplate) { fclose(assetErrorFileSoundTemplate); }
|
||||
if (assetErrorFileTerrain) { fclose(assetErrorFileTerrain); }
|
||||
if (assetErrorFileTexture) { fclose(assetErrorFileTexture); }
|
||||
if (assetErrorFileTextureRenderer) { fclose(assetErrorFileTextureRenderer); }
|
||||
}
|
||||
}
|
||||
|
||||
// UnSupported Assets
|
||||
@@ -411,6 +391,26 @@ void DataLint::report()
|
||||
|
||||
fclose(fp);
|
||||
}
|
||||
|
||||
if (assetErrorFileAll) { fclose(assetErrorFileAll); }
|
||||
if (assetErrorFileAllFatal) { fclose(assetErrorFileAllFatal); }
|
||||
if (assetErrorFileAllWarning) { fclose(assetErrorFileAllWarning); }
|
||||
if (assetErrorFileObjectTemplate) { fclose(assetErrorFileObjectTemplate); }
|
||||
|
||||
if (m_mode == M_client)
|
||||
{
|
||||
if (assetErrorFileAppearance) { fclose(assetErrorFileAppearance); }
|
||||
if (assetErrorFileArrangementDescriptor) { fclose(assetErrorFileArrangementDescriptor); }
|
||||
if (assetErrorFileLocalizedStringTable) { fclose(assetErrorFileLocalizedStringTable); }
|
||||
if (assetErrorFilePortalProperty) { fclose(assetErrorFilePortalProperty); }
|
||||
if (assetErrorFileShaderTemplate) { fclose(assetErrorFileShaderTemplate); }
|
||||
if (assetErrorFileSkyBox) { fclose(assetErrorFileSkyBox); }
|
||||
if (assetErrorFileSlotDescriptor) { fclose(assetErrorFileSlotDescriptor); }
|
||||
if (assetErrorFileSoundTemplate) { fclose(assetErrorFileSoundTemplate); }
|
||||
if (assetErrorFileTerrain) { fclose(assetErrorFileTerrain); }
|
||||
if (assetErrorFileTexture) { fclose(assetErrorFileTexture); }
|
||||
if (assetErrorFileTextureRenderer) { fclose(assetErrorFileTextureRenderer); }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -215,14 +215,16 @@ VisibleExpandableEntry * VisibleExpandableEntry::findOrAddExpandableChild(char c
|
||||
bool VisibleExpandableEntry::pruneInvisibleChildren()
|
||||
{
|
||||
for (Children::iterator i = m_children.begin(); i != m_children.end(); )
|
||||
{
|
||||
if ((*i)->m_visible == false)
|
||||
{
|
||||
delete *i;
|
||||
m_children.erase(i);
|
||||
i = m_children.erase(i);
|
||||
}
|
||||
else
|
||||
{
|
||||
++i;
|
||||
|
||||
}
|
||||
}
|
||||
bool const result = ms_destroyedSelected;
|
||||
ms_destroyedSelected = false;
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user