diff options
author | Robin Gareus <robin@gareus.org> | 2016-04-15 03:24:37 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-04-15 03:24:37 +0200 |
commit | 52a8bad4a26f5ac75598ee0674d192dad5ade857 (patch) | |
tree | 93a7388a6f487c95fbb947502b5b4a722be2a553 | |
parent | 9041fc8d54f4f2e2a3871b05707569ea870f5520 (diff) |
luaproc error logging
-rw-r--r-- | libs/ardour/luaproc.cc | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/libs/ardour/luaproc.cc b/libs/ardour/luaproc.cc index fc9e5de537..31a5dd8785 100644 --- a/libs/ardour/luaproc.cc +++ b/libs/ardour/luaproc.cc @@ -114,9 +114,7 @@ LuaProc::init () _stats_avg[0] = _stats_avg[1] = _stats_max[0] = _stats_max[1] = _stats_cnt = 0; #endif -#ifndef NDEBUG lua.Print.connect (sigc::mem_fun (*this, &LuaProc::lua_print)); -#endif // register session object lua_State* L = lua.getState (); LuaBindings::stddef (L); @@ -150,6 +148,7 @@ LuaProc::init () void LuaProc::lua_print (std::string s) { std::cout <<"LuaProc: " << s << "\n"; + PBD::error << "LuaProc: " << s << "\n"; } bool @@ -659,8 +658,9 @@ LuaProc::connect_and_run (BufferSet& bufs, (*_lua_dsp)(in_map, out_map, nframes); } } catch (luabridge::LuaException const& e) { + PBD::error << "LuaException: " << e.what () << "\n"; #ifndef NDEBUG - printf ("LuaException: %s\n", e.what ()); + std::cerr << "LuaException: " << e.what () << "\n"; #endif return -1; } @@ -961,10 +961,7 @@ LuaProc::setup_lua_inline_gui (LuaState *lua_gui) LuaBindings::common (LG); LuaBindings::dsp (LG); -#ifndef NDEBUG lua_gui->Print.connect (sigc::mem_fun (*this, &LuaProc::lua_print)); -#endif - lua_gui->do_command ("function ardour () end"); lua_gui->do_command (_script); |