Fix (unreported) crash when iterating on depsgraph instances from RNA.
authorBastien Montagne <montagne29@wanadoo.fr>
Wed, 6 Feb 2019 19:59:29 +0000 (20:59 +0100)
committerBastien Montagne <montagne29@wanadoo.fr>
Wed, 6 Feb 2019 20:13:52 +0000 (21:13 +0100)
commitac9daf3a27df8693fc2a6852d52bea5c33ca6c56
tree7c9a0e27e7a97996f0251d8602645af909fc7926
parent766741b0aa8c7325bddb0e68c5af7b8610720879
Fix (unreported) crash when iterating on depsgraph instances from RNA.

This is a follow-up to rBb44e6f2b3d32, for some reason that issue was
not detected back then: in some cases, DEG_iterator_objects_next() will
free the temp list of dupli objects once it does not need it anymore,
henceforth freeing the dupli_object_current memory of the DEGObjectIterData
that we are storing in the RNA_Depsgraph_Instances_Iterator struct.

And yes, the uglyness of that hack is getting even better now...

Found while trying to export dupliobjects with FBX...
source/blender/makesrna/intern/rna_depsgraph.c