Robert Müller
|
65aa584b9f
|
Remove redundant conditional expressions
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)
^
```
|
2022-11-29 23:32:28 +01:00 |
|
Rafael Fontenelle
|
cd14660307
|
Fix misspellings
|
2022-10-25 13:51:56 -03:00 |
|
Chairn
|
01edaec628
|
Format vector variables names (fixes #5209)
|
2022-06-11 21:38:49 +02:00 |
|
Robert Müller
|
4b36584ca1
|
Organize engine-client includes
|
2022-05-29 21:24:43 +02:00 |
|
Jupeyy
|
b8f96ce500
|
Allow GLES3 coexists with OpenGL on Linux
|
2021-05-02 04:39:02 +02:00 |
|