diff --git a/gtk2_ardour/editor_sources.cc b/gtk2_ardour/editor_sources.cc index f8b4d65b61..6ba481bec6 100644 --- a/gtk2_ardour/editor_sources.cc +++ b/gtk2_ardour/editor_sources.cc @@ -495,10 +495,17 @@ EditorSources::add_source (boost::shared_ptr region) * if there's some other kind of source, we ignore it (for now) */ boost::shared_ptr fs = boost::dynamic_pointer_cast (region->source()); - if (!fs || fs->empty()) { + if (!fs) { return; } + if (fs->empty()) { + /* MIDI sources are allowed to be empty */ + if (!boost::dynamic_pointer_cast (region->source())) { + return; + } + } + region->DropReferences.connect (remove_region_connections, MISSING_INVALIDATOR, boost::bind (&EditorSources::remove_weak_region, this, boost::weak_ptr (region)), gui_context()); TreeModel::Row row = *(_model->append());