mirror of
https://github.com/love2d/love.git
synced 2026-08-17 19:23:38 +02:00
Thread:getKeys needs to return a 1-indexed table
This commit is contained in:
@@ -135,7 +135,7 @@ namespace thread
|
|||||||
std::vector<std::string> keys = t->getKeys();
|
std::vector<std::string> keys = t->getKeys();
|
||||||
t->unlock();
|
t->unlock();
|
||||||
lua_createtable(L, keys.size(), 0);
|
lua_createtable(L, keys.size(), 0);
|
||||||
int i = 0;
|
int i = 1;
|
||||||
for (std::vector<std::string>::iterator it = keys.begin(); it != keys.end(); it++)
|
for (std::vector<std::string>::iterator it = keys.begin(); it != keys.end(); it++)
|
||||||
{
|
{
|
||||||
lua_pushnumber(L, i++);
|
lua_pushnumber(L, i++);
|
||||||
|
|||||||
Reference in New Issue
Block a user