From ab713ee1f45f681ee27e3573dbfd373d9a105b20 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Mon, 29 Nov 2010 00:18:26 +0000 Subject: fix [#24921] Crash after inserting keyframing UV coords and changing frame in edit mode zero length arrays were still having their members accessible. --- source/blender/makesrna/intern/rna_access.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/blender/makesrna/intern/rna_access.c b/source/blender/makesrna/intern/rna_access.c index 1cac7aefdfa..db8710aec2a 100644 --- a/source/blender/makesrna/intern/rna_access.c +++ b/source/blender/makesrna/intern/rna_access.c @@ -2794,6 +2794,10 @@ void rna_iterator_array_begin(CollectionPropertyIterator *iter, void *ptr, int i if(ptr == NULL) length= 0; + else if (length == 0) { + ptr= NULL; + itemsize= 0; + } internal= MEM_callocN(sizeof(ArrayIterator), "ArrayIterator"); internal->ptr= ptr; -- cgit v1.2.3