diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-01-04 06:02:58 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-01-04 09:38:11 +0300 |
commit | a5081896bc0416f9b64ae8e488bfe1cc2042ca7e (patch) | |
tree | 3d5a1c29a845adef18d05b623eeee5f9aacefae9 /source/blender/modifiers | |
parent | b5c2a75d26dbd5725ee5c8f361db35aedb45efdf (diff) |
Cleanup: redundant code, minor inconsistencies
- Remove ternary operators when both values are the same.
- Remove break after return.
- Remove redundant NULL checks for code which handles
those cases immediately beforehand.
Diffstat (limited to 'source/blender/modifiers')
-rw-r--r-- | source/blender/modifiers/intern/MOD_smooth.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/source/blender/modifiers/intern/MOD_smooth.c b/source/blender/modifiers/intern/MOD_smooth.c index 618ccc78279..c5011ed15c1 100644 --- a/source/blender/modifiers/intern/MOD_smooth.c +++ b/source/blender/modifiers/intern/MOD_smooth.c @@ -106,9 +106,7 @@ static void smoothModifier_do( uint *num_accumulated_vecs = MEM_calloc_arrayN( (size_t)numVerts, sizeof(*num_accumulated_vecs), __func__); if (!num_accumulated_vecs) { - if (accumulated_vecs) { - MEM_freeN(accumulated_vecs); - } + MEM_freeN(accumulated_vecs); return; } |