From 99c2d589d11114a714a4296c6283b961972cd24d Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Mon, 6 Dec 2010 13:59:59 +0000 Subject: [PATCH] Don't crash if get_action() is called before the UI manager is created. Sort-of fix for #3571. git-svn-id: svn://localhost/ardour2/branches/3.0@8199 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/gtkmm2ext/actions.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libs/gtkmm2ext/actions.cc b/libs/gtkmm2ext/actions.cc index e9ff15fa46..43a2a24d2d 100644 --- a/libs/gtkmm2ext/actions.cc +++ b/libs/gtkmm2ext/actions.cc @@ -237,6 +237,10 @@ ActionManager::get_action (const char* group_name, const char* action_name) gtkmm2.6, so we fall back to the C level. */ + if (ui_manager == 0) { + return RefPtr (); + } + GList* list = gtk_ui_manager_get_action_groups (ui_manager->gobj()); GList* node; RefPtr act;