diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-09-11 06:49:46 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-09-11 06:49:46 +0400 |
commit | 7aedfd654bc1cba8b73be42a6938dc9857876069 (patch) | |
tree | d52d0575f79c3c2710b641eacb5c14af9888b9d3 | |
parent | bae66459dffb75e660b375cf8e6fff5d8b9c9b73 (diff) |
Fix T41778: Crash on animate boids xith a goal
No need to copy/restore entire object struct (just to read location)
-rw-r--r-- | source/blender/blenkernel/intern/effect.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/effect.c b/source/blender/blenkernel/intern/effect.c index 4859aa8f791..24ee470eaa7 100644 --- a/source/blender/blenkernel/intern/effect.c +++ b/source/blender/blenkernel/intern/effect.c @@ -630,8 +630,7 @@ int get_effector_data(EffectorCache *eff, EffectorData *efd, EffectedPoint *poin } else { /* use center of object for distance calculus */ - Object *ob = eff->ob; - Object obcopy = *ob; + const Object *ob = eff->ob; /* use z-axis as normal*/ normalize_v3_v3(efd->nor, ob->obmat[2]); @@ -654,8 +653,6 @@ int get_effector_data(EffectorCache *eff, EffectorData *efd, EffectedPoint *poin if (real_velocity) copy_v3_v3(efd->vel, eff->velocity); - *eff->ob = obcopy; - efd->size = 0.0f; ret = 1; |