From be85889464470e66e33f6f09f3cf1a64ef3c5063 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Tue, 24 Aug 2010 22:07:53 +0000 Subject: fix load+save of plugin parameter automation git-svn-id: svn://localhost/ardour2/branches/3.0@7678 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/selection.cc | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'gtk2_ardour/selection.cc') diff --git a/gtk2_ardour/selection.cc b/gtk2_ardour/selection.cc index 5b1bba1f3c..3e9cd41698 100644 --- a/gtk2_ardour/selection.cc +++ b/gtk2_ardour/selection.cc @@ -1140,9 +1140,15 @@ Selection::set_state (XMLNode const & node, int) assert (rtv); boost::shared_ptr atv = rtv->automation_child (EventTypeMap::instance().new_parameter (prop_parameter->value ())); - assert (atv); - - add (atv.get()); + + /* the automation could be for an entity that was never saved + in the session file. Don't freak out if we can't find + it. + */ + + if (atv) { + add (atv.get()); + } } } -- cgit v1.2.3