diff options
author | Robin Gareus <robin@gareus.org> | 2017-11-23 10:38:52 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2017-11-23 10:38:52 +0100 |
commit | 12a510271306df4af7a7db241ed7cf07f35fdf06 (patch) | |
tree | 6ffcda5a5384f65f45110a08d9c3483d1d052948 /gtk2_ardour/luainstance.cc | |
parent | 3009fd75749e9bfe7ef3748eb94226b53cbbe264 (diff) |
Catch exceptions by const reference
Diffstat (limited to 'gtk2_ardour/luainstance.cc')
-rw-r--r-- | gtk2_ardour/luainstance.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk2_ardour/luainstance.cc b/gtk2_ardour/luainstance.cc index a37270e112..156ad11d34 100644 --- a/gtk2_ardour/luainstance.cc +++ b/gtk2_ardour/luainstance.cc @@ -1323,7 +1323,7 @@ LuaInstance::interactive_add (LuaScriptInfo::ScriptType type, int id) try { script = Glib::file_get_contents (spi->path); - } catch (Glib::FileError e) { + } catch (Glib::FileError const& e) { string msg = string_compose (_("Cannot read script '%1': %2"), spi->path, e.what()); Gtk::MessageDialog am (msg); am.run (); @@ -1360,7 +1360,7 @@ LuaInstance::interactive_add (LuaScriptInfo::ScriptType type, int id) string msg = string_compose (_("Session script '%1' instantiation failed: %2"), spd.name(), e.what ()); Gtk::MessageDialog am (msg); am.run (); - } catch (SessionException e) { + } catch (SessionException const& e) { string msg = string_compose (_("Loading Session script '%1' failed: %2"), spd.name(), e.what ()); Gtk::MessageDialog am (msg); am.run (); |