Use PBD::copy_file in Session::create() to copy the template file.
[ardour.git] / libs / ardour / control_protocol_manager.cc
index c79aa74698fc9c56383053106270a607303aed38..00c05b280039fef867b74767bd9f1700f65ebee1 100644 (file)
@@ -96,8 +96,10 @@ ControlProtocolManager::drop_session ()
                
                for (list<ControlProtocolInfo*>::iterator p = control_protocol_info.begin(); p != control_protocol_info.end(); ++p) {
                        // otherwise the ControlProtocol instances are not recreated in set_session
-                       (*p)->requested = true;
-                       (*p)->protocol = 0;
+                       if ((*p)->protocol) {
+                               (*p)->requested = true;
+                               (*p)->protocol = 0;
+                       }
                }
        }
 }