mirror of
https://github.com/ddnet/ddnet.git
synced 2024-10-19 23:38:19 +00:00
65aa584b9f
According to cppcheck's `redundantCondition` and `multiCondition` errors: ``` src\engine\client\backend\glsl_shader_compiler.cpp:70:39: style: Redundant condition: The condition '*(pBuff+1)' is redundant since '*(pBuff+1) == 'i'' is sufficient. [redundantCondition] if(*pBuff == ' ' && *(pBuff + 1) && *(pBuff + 1) == 'i' && *(pBuff + 2) == 'n') ^ src\engine\client\backend\glsl_shader_compiler.cpp:98:45: style: Redundant condition: The condition '*(pBuff+1)' is redundant since '*(pBuff+1) == 'u'' is sufficient. [redundantCondition] else if(*pBuff == 'o' && *(pBuff + 1) && *(pBuff + 1) == 'u' && *(pBuff + 2) == 't') ^ src\game\client\gameclient.cpp:1665:62: style: Redundant condition: m_aShowOthers[g_Config.m_ClDummy]!=SHOW_OTHERS_NOT_SET. 'A || (!A && B)' is equivalent to 'A || B' [redundantCondition] if(m_aShowOthers[g_Config.m_ClDummy] == SHOW_OTHERS_NOT_SET || (m_aShowOthers[g_Config.m_ClDummy] != SHOW_OTHERS_NOT_SET && m_aShowOthers[g_Config.m_ClDummy] != g_Config.m_ClShowOthers)) ^ src\game\client\prediction\entities\projectile.cpp:104:34: style: Redundant condition: pTargetChr. '!A || (A && B)' is equivalent to '!A || B' [redundantCondition] if(m_Explosive && (!pTargetChr || (pTargetChr && (!m_Freeze || (m_Type == WEAPON_SHOTGUN && Collide))))) ^ src\engine\client\backend\vulkan\backend_vulkan.cpp:6588:11: style: Expression is always true because 'else if' condition is opposite to previous condition at line 6578. [multiCondition] else if(!pCommand->m_ByResize) ^ src\engine\client\backend\vulkan\backend_vulkan.cpp:6578:14: note: first condition if(pCommand->m_ByResize) ^ src\engine\client\backend\vulkan\backend_vulkan.cpp:6588:11: note: else if condition is opposite to first condition else if(!pCommand->m_ByResize) ^ ``` |
||
---|---|---|
.. | ||
backend | ||
backend_sdl.cpp | ||
backend_sdl.h | ||
blocklist_driver.cpp | ||
blocklist_driver.h | ||
checksum.h | ||
client.cpp | ||
client.h | ||
demoedit.cpp | ||
demoedit.h | ||
discord.cpp | ||
favorites.cpp | ||
friends.cpp | ||
friends.h | ||
ghost.cpp | ||
ghost.h | ||
graphics_defines.h | ||
graphics_threaded.cpp | ||
graphics_threaded.h | ||
input.cpp | ||
input.h | ||
keynames.h | ||
notifications.cpp | ||
notifications.h | ||
serverbrowser.cpp | ||
serverbrowser.h | ||
serverbrowser_http.cpp | ||
serverbrowser_http.h | ||
serverbrowser_ping_cache.cpp | ||
serverbrowser_ping_cache.h | ||
sound.cpp | ||
sound.h | ||
sqlite.cpp | ||
steam.cpp | ||
text.cpp | ||
updater.cpp | ||
updater.h | ||
video.cpp | ||
video.h |