diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2019-01-16 10:59:45 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2019-01-16 10:59:45 +0100 |
commit | 053d7f37650cc03261dabf09b860c530daed4fc9 (patch) | |
tree | 8000425cc4ed60ca19c96e84a49dd9ba761bec58 /scene | |
parent | e7844505b18fecebad1ce84ddc20fe510c469028 (diff) |
Fix some errors found by static analysis
Fixes items 10, 16 and 19 from PVS-Studio blog post
in #24014.
Diffstat (limited to 'scene')
-rw-r--r-- | scene/animation/animation_blend_space_1d.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/animation/animation_blend_space_1d.cpp b/scene/animation/animation_blend_space_1d.cpp index 360ba84374..dded44b990 100644 --- a/scene/animation/animation_blend_space_1d.cpp +++ b/scene/animation/animation_blend_space_1d.cpp @@ -110,7 +110,7 @@ void AnimationNodeBlendSpace1D::add_blend_point(const Ref<AnimationRootNode> &p_ if (p_at_index == -1 || p_at_index == blend_points_used) { p_at_index = blend_points_used; } else { - for (int i = blend_points_used - 1; i > p_at_index; i++) { + for (int i = blend_points_used - 1; i > p_at_index; i--) { blend_points[i] = blend_points[i - 1]; } } |