diff options
| author | Naios <naios-dev@live.de> | 2015-03-11 08:53:13 +0100 |
|---|---|---|
| committer | Naios <naios-dev@live.de> | 2015-03-11 08:53:13 +0100 |
| commit | 9a61049f88835fd6bdb75905f042583d038d0667 (patch) | |
| tree | d567eb1c294499afea9fc74970ec8ed71000dd26 /src/server/game/Spells/Spell.cpp | |
| parent | 163bd334d0891463c9082df5d251e51f046713f1 (diff) | |
Core/Game: Fix some issues detected by static analysis.
* Possible inefficient checking for 'list' emptiness.
* Variable '_scheduledScripts' is assigned in constructor body.
Consider performing initialization in initialization list.
* Variable 'Text' is assigned in constructor body.
Consider performing initialization in initialization list.
* Possible inefficient checking for 'm_loadedScripts' emptiness.
Diffstat (limited to 'src/server/game/Spells/Spell.cpp')
| -rw-r--r-- | src/server/game/Spells/Spell.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp index a307b60f76b..919f11a5db4 100644 --- a/src/server/game/Spells/Spell.cpp +++ b/src/server/game/Spells/Spell.cpp @@ -7229,7 +7229,7 @@ void Spell::CallScriptDestinationTargetSelectHandlers(SpellDestination& target, bool Spell::CheckScriptEffectImplicitTargets(uint32 effIndex, uint32 effIndexToCheck) { // Skip if there are not any script - if (!m_loadedScripts.size()) + if (m_loadedScripts.empty()) return true; for (std::list<SpellScript*>::iterator itr = m_loadedScripts.begin(); itr != m_loadedScripts.end(); ++itr) |
