diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-01-18 02:58:54 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-01-18 03:01:17 +0300 |
commit | 27dff3fbc1e74aa6613d68a0d9f9b0096fc86f6e (patch) | |
tree | 91c4fb3bbe944a4f9e0e6d72a25d12310872f849 /source/blender/modifiers/intern/MOD_fluidsim_util.c | |
parent | 8400b4b566350bd9d726a07627e74f5a995280da (diff) | |
parent | e6df02861e17f75d4dd243776f35208681b78465 (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/modifiers/intern/MOD_fluidsim_util.c')
-rw-r--r-- | source/blender/modifiers/intern/MOD_fluidsim_util.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_fluidsim_util.c b/source/blender/modifiers/intern/MOD_fluidsim_util.c index 3684e947fe0..c9f475ad228 100644 --- a/source/blender/modifiers/intern/MOD_fluidsim_util.c +++ b/source/blender/modifiers/intern/MOD_fluidsim_util.c @@ -239,7 +239,7 @@ static DerivedMesh *fluidsim_read_obj(const char *filename, const MPoly *mp_exam return NULL; } - normals = MEM_callocN(sizeof(short) * numverts * 3, "fluid_tmp_normals"); + normals = MEM_calloc_arrayN(numverts, 3 * sizeof(short), "fluid_tmp_normals"); if (!normals) { if (dm) dm->release(dm); @@ -384,7 +384,7 @@ static void fluidsim_read_vel_cache(FluidsimModifierData *fluidmd, DerivedMesh * if (fss->domainNovecgen > 0) return; - fss->meshVelocities = MEM_callocN(sizeof(FluidVertexVelocity) * dm->getNumVerts(dm), "Fluidsim_velocities"); + fss->meshVelocities = MEM_calloc_arrayN(dm->getNumVerts(dm), sizeof(FluidVertexVelocity), "Fluidsim_velocities"); fss->totvert = totvert; velarray = fss->meshVelocities; |