diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2018-07-16 23:29:26 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2018-07-16 23:29:26 +0300 |
commit | b85be88655ccc408d9545a077f33502fd583eb2e (patch) | |
tree | 6b405dafdc7d92d83a92c7635b569486a24dff47 /source/blender/blenkernel/intern/ipo.c | |
parent | e6af8758c86099790b003454195c4a748251c6a4 (diff) |
Fix (IRC-reported) wrong usercount handling of deprecated IPO datablocks.
versionning code would unref those twice... Reported by @ßergey on IRC, thanks!
Diffstat (limited to 'source/blender/blenkernel/intern/ipo.c')
-rw-r--r-- | source/blender/blenkernel/intern/ipo.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/ipo.c b/source/blender/blenkernel/intern/ipo.c index 9d8ca1e352c..fd8cb6d6d98 100644 --- a/source/blender/blenkernel/intern/ipo.c +++ b/source/blender/blenkernel/intern/ipo.c @@ -1732,8 +1732,7 @@ void do_versions_ipos_to_animato(Main *bmain) /* IPO first to take into any non-NLA'd Object Animation */ if (ob->ipo) { ipo_to_animdata(bmain, id, ob->ipo, NULL, NULL, NULL); - - id_us_min(&ob->ipo->id); + /* No need to id_us_min ipo ID here, ipo_to_animdata already does it. */ ob->ipo = NULL; } @@ -1766,7 +1765,7 @@ void do_versions_ipos_to_animato(Main *bmain) /* IPO second... */ if (ob->ipo) { ipo_to_animdata(bmain, id, ob->ipo, NULL, NULL, NULL); - id_us_min(&ob->ipo->id); + /* No need to id_us_min ipo ID here, ipo_to_animdata already does it. */ ob->ipo = NULL; { |