From 054bcbd76ce2a7f0d8be52df613bf6af3f14634c Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Thu, 9 Aug 2007 01:41:49 -0400 Subject: tLENGTH and tSTRINGRESULT parameters are handled properly; src/lua_interface.c If p1_type == tLENGTH and p2_type == tSTRINGRESULT, both parameters can be ignored because p1_type is filled with the length of p2_type, which is not needed. --- src/lua_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/lua_interface.c') diff --git a/src/lua_interface.c b/src/lua_interface.c index 62678c96..8553a36a 100644 --- a/src/lua_interface.c +++ b/src/lua_interface.c @@ -605,7 +605,7 @@ LF l_call_scintilla(LS *lua, ScintillaObject *sci, int msg, params_needed = 0; } else if (p2_type == tSTRINGRESULT) { string_return = true; - params_needed = 1; + params_needed = p1_type == tLENGTH ? 0 : 1; } if (params_needed > 0) params[0] = l_toscintillaparam(lua, p1_type, arg); if (params_needed > 1) params[1] = l_toscintillaparam(lua, p2_type, arg); -- cgit v1.2.3