diff options
author | Carl Hetherington <carl@carlh.net> | 2010-12-06 13:59:59 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2010-12-06 13:59:59 +0000 |
commit | 99c2d589d11114a714a4296c6283b961972cd24d (patch) | |
tree | 17243d7a19d1e428176765beabc381866c2d448c /libs/gtkmm2ext/actions.cc | |
parent | fdc9e200bebff6f3a9dbb50f22a23aa4e469f993 (diff) |
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
Diffstat (limited to 'libs/gtkmm2ext/actions.cc')
-rw-r--r-- | libs/gtkmm2ext/actions.cc | 4 |
1 files changed, 4 insertions, 0 deletions
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<Action> (); + } + GList* list = gtk_ui_manager_get_action_groups (ui_manager->gobj()); GList* node; RefPtr<Action> act; |