From 7e121f4e13581d59427750af4fa3d2db359a9f9a Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Sun, 2 Jul 2023 23:53:29 +0200 Subject: [PATCH] Fix alloc-dealloc-mismatch (malloc vs operator delete) --- gtk2_ardour/ardour_ui_session.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gtk2_ardour/ardour_ui_session.cc b/gtk2_ardour/ardour_ui_session.cc index 41c53c0d1b..c2b96517a8 100644 --- a/gtk2_ardour/ardour_ui_session.cc +++ b/gtk2_ardour/ardour_ui_session.cc @@ -442,7 +442,7 @@ ARDOUR_UI::load_session_stage_two (const std::string& path, const std::string& s (void) msg.run (); msg.hide (); - delete escaped_error_txt; + g_free (escaped_error_txt); goto out; } @@ -473,7 +473,7 @@ ARDOUR_UI::load_session_stage_two (const std::string& path, const std::string& s (void) msg.run (); msg.hide (); - delete escaped_error_txt; + g_free (escaped_error_txt); goto out; } @@ -501,7 +501,7 @@ ARDOUR_UI::load_session_stage_two (const std::string& path, const std::string& s (void) msg.run (); msg.hide (); - delete escaped_error_txt; + g_free (escaped_error_txt); goto out; } @@ -700,7 +700,7 @@ ARDOUR_UI::build_session_stage_two (std::string const& path, std::string const& msg.set_title (_("Loading Error")); msg.set_position (Gtk::WIN_POS_CENTER); msg.run (); - delete escaped_error_txt; + g_free (escaped_error_txt); return -1; } catch (Glib::Error const& e) { @@ -724,7 +724,7 @@ ARDOUR_UI::build_session_stage_two (std::string const& path, std::string const& msg.set_title (_("Loading Error")); msg.set_position (Gtk::WIN_POS_CENTER); msg.run (); - delete escaped_error_txt; + g_free (escaped_error_txt); return -1; } catch (...) { @@ -745,7 +745,7 @@ ARDOUR_UI::build_session_stage_two (std::string const& path, std::string const& msg.set_title (_("Loading Error")); msg.set_position (Gtk::WIN_POS_CENTER); msg.run (); - delete escaped_error_txt; + g_free (escaped_error_txt); return -1; }