Replace a bunch of potential crashes with graceful handling of the situation.
[ardour.git] / gtk2_ardour / automation_streamview.cc
index 65df722e3c1c5a426617be36a7d4b3c2e7dad79e..7b2c1ab751b08a4150fd3d993f27526ce37b748d 100644 (file)
@@ -249,9 +249,9 @@ AutomationStreamView::interpolation () const
        }
 
        AutomationRegionView* v = dynamic_cast<AutomationRegionView*> (region_views.front());
-       assert (v);
-
-       return v->line()->the_list()->interpolation ();
+       if (v) {
+               return v->line()->the_list()->interpolation ();
+       }
 }
 
 /** Clear all automation displayed in this view */