forked from mia/Aegisub
Update #1013 with a temporary fix. Changes to wxString in wx 2.9 caused the issue, because wxString::c_string() no longer returned a wchar_t* or char* and thus those weren't caught by the proper exception handler.
This fix should be replaced with a proper exception type later. Originally committed to SVN as r3813.
This commit is contained in:
parent
815ad4b8ca
commit
3e52c7a592
1 changed files with 2 additions and 2 deletions
|
@ -229,7 +229,7 @@ namespace Automation4 {
|
|||
if (lua_load(L, script_reader.reader_func, &script_reader, GetPrettyFilename().mb_str(wxConvUTF8))) {
|
||||
wxString *err = new wxString(lua_tostring(L, -1), wxConvUTF8);
|
||||
err->Prepend(_T("Error loading Lua script \"") + GetPrettyFilename() + _T("\":\n\n"));
|
||||
throw err->c_str();
|
||||
throw err->wx_str();
|
||||
}
|
||||
_stackcheck.check_stack(1);
|
||||
// and execute it
|
||||
|
@ -239,7 +239,7 @@ namespace Automation4 {
|
|||
// error occurred, assumed to be on top of Lua stack
|
||||
wxString *err = new wxString(lua_tostring(L, -1), wxConvUTF8);
|
||||
err->Prepend(_T("Error initialising Lua script \"") + GetPrettyFilename() + _T("\":\n\n"));
|
||||
throw err->c_str();
|
||||
throw err->wx_str();
|
||||
}
|
||||
_stackcheck.check_stack(0);
|
||||
lua_getglobal(L, "version");
|
||||
|
|
Loading…
Reference in a new issue