Small optimization, improves compatibility with DLL version of Lua runtime

This commit is contained in:
Jason Perkins 2014-06-26 10:40:24 -04:00
parent 019ba5dcfc
commit d5ef6f4c32
2 changed files with 2 additions and 4 deletions

View File

@ -88,9 +88,8 @@ int path_getabsolute(lua_State* L)
do_getabsolute(buffer, value, relative_to);
lua_pop(L, 1);
lua_pushnumber(L, ++i);
lua_pushstring(L, buffer);
lua_settable(L, -4);
lua_rawseti(L, -3, ++i);
}
return 1;
}

View File

@ -47,9 +47,8 @@ int path_translate(lua_State* L)
translate(buffer, value, sep[0]);
lua_pop(L, 1);
lua_pushnumber(L, ++i);
lua_pushstring(L, buffer);
lua_settable(L, 2);
lua_rawseti(L, -3, ++i);
}
return 1;
}