Fix Session > New (cancel retains the current session if any)
authorRobin Gareus <robin@gareus.org>
Thu, 3 Aug 2017 16:43:41 +0000 (18:43 +0200)
committerRobin Gareus <robin@gareus.org>
Thu, 3 Aug 2017 17:25:14 +0000 (19:25 +0200)
gtk2_ardour/ardour_ui.cc
gtk2_ardour/ardour_ui_ed.cc

index d6389d68b489dcec4748ec878f3b49ad338a42bb..31ddbeca291f6badea64798ee2a424c35e1af394 100644 (file)
@@ -3483,6 +3483,7 @@ ARDOUR_UI::get_session_parameters (bool quit_on_cancel, bool should_be_new, stri
                                        // user quits from the main 'Session Setup' dialog (i.e. reaching this
                                        // point does NOT indicate an abnormal termination). Therefore, let's
                                        // behave gracefully (i.e. let's do some cleanup) before we call exit()
+                                       assert (!_session);
                                        ARDOUR::cleanup ();
                                        pthread_cancel_all ();
 
index bc40973f2f38f2f4886b10a54a9c0b0f88541dfe..b1a76f3faad3d7e897acfff3a2fa887ecd20da7b 100644 (file)
@@ -162,7 +162,7 @@ ARDOUR_UI::install_actions ()
 
        /* the real actions */
 
-       act = global_actions.register_action (main_actions, X_("New"), _("New..."),  hide_return (sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::get_session_parameters), true, true, "")));
+       act = global_actions.register_action (main_actions, X_("New"), _("New..."),  hide_return (sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::get_session_parameters), false, true, "")));
 
        global_actions.register_action (main_actions, X_("Open"), _("Open..."),  sigc::mem_fun(*this, &ARDOUR_UI::open_session));
        global_actions.register_action (main_actions, X_("Recent"), _("Recent..."),  sigc::mem_fun(*this, &ARDOUR_UI::open_recent_session));