From 23a02bbead6d423bba1226bd84d4b2248af7ad39 Mon Sep 17 00:00:00 2001 From: Ton Roosendaal Date: Sun, 12 Oct 2008 13:16:23 +0000 Subject: Bugfix, studio report by Pablo Venomgfx - insert key crashed when object ipo was in action, but action got unlinked from object --- source/blender/src/keyframing.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'source/blender/src/keyframing.c') diff --git a/source/blender/src/keyframing.c b/source/blender/src/keyframing.c index c5777b9c2a6..e61d8140183 100644 --- a/source/blender/src/keyframing.c +++ b/source/blender/src/keyframing.c @@ -1347,10 +1347,12 @@ static void commonkey_context_getv3d (ListBase *sources, bKeyingContext **ksc) if (achan && achan->ipo) cks->ipo= achan->ipo; } - - /* deselect all ipo-curves */ - for (icu= cks->ipo->curve.first; icu; icu= icu->next) { - icu->flag &= ~IPO_SELECT; + /* cks->ipo can be NULL while editing */ + if(cks->ipo) { + /* deselect all ipo-curves */ + for (icu= cks->ipo->curve.first; icu; icu= icu->next) { + icu->flag &= ~IPO_SELECT; + } } } } -- cgit v1.2.3