attempt fix for LTC slave when locating
[ardour.git] / libs / ardour / luascripting.cc
index e2fc9d49f109a5c2572cf7648e771c6ed3430dc0..5d0b45aaf5506888fe3bc126f11a37c485211846 100644 (file)
@@ -294,9 +294,11 @@ LuaScripting::scan_script (const std::string &fn, const std::string &sc)
 
                luabridge::LuaRef lua_ss = luabridge::getGlobal (L, "session_setup");
                if (lua_ss.isFunction ()) {
-                       if (lua_ss () == true) {
-                               lsi->subtype |= LuaScriptInfo::SessionSetup;
-                       }
+                       try {
+                               if (lua_ss () == true) {
+                                       lsi->subtype |= LuaScriptInfo::SessionSetup;
+                               }
+                       } catch (...) { }
                }
 
        }
@@ -385,7 +387,7 @@ LuaScriptParams::script_params (const std::string& s, const std::string &pname,
                } else {
                        lua.do_command (s);
                }
-       } catch (luabridge::LuaException const& e) {
+       } catch (...) {
                return rv;
        }
 
@@ -482,7 +484,7 @@ LuaScripting::try_compile (const std::string& script, const LuaScriptParamList&
                cerr << e.what() << "\n";
 #endif
                lua_print (e.what());
-       }
+       } catch (...) { }
 
        return false;
 }
@@ -513,7 +515,7 @@ LuaScripting::get_factory_bytecode (const std::string& script, const std::string
                if (lua_factory.isFunction()) {
                        return (lua_dump(lua_factory)).cast<std::string> ();
                }
-       } catch (luabridge::LuaException const& e) { }
+       } catch (...) { }
        return "";
 }