Skip to content

Commit

Permalink
Merge branch 'master' into v2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Pall committed Mar 22, 2016
2 parents be25592 + ddadbe8 commit cf3e01e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/host/buildvm_fold.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

/* Context for the folding hash table generator. */
static int lineno;
static int funcidx;
static uint32_t funcidx;
static uint32_t foldkeys[BUILD_MAX_FOLD];
static uint32_t nkeys;

Expand Down
1 change: 1 addition & 0 deletions src/host/genminilua.lua
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,7 @@ local function strip_unused3(src)
src = gsub(src, "if%([^\n]*hookmask[^\n]*&&\n[^\n]*%b{}\n", "")
src = gsub(src, "(twoto%b()%()", "%1(size_t)")
src = gsub(src, "i<sizenode", "i<(int)sizenode")
src = gsub(src, "cast%(unsigned int,key%-1%)", "cast(unsigned int,key)-1")
return gsub(src, "\n\n+", "\n")
end

Expand Down
2 changes: 1 addition & 1 deletion src/host/minilua.c
Original file line number Diff line number Diff line change
Expand Up @@ -1606,7 +1606,7 @@ luaC_barriert(L,t,key);
return gval(mp);
}
static const TValue*luaH_getnum(Table*t,int key){
if(cast(unsigned int,key-1)<cast(unsigned int,t->sizearray))
if(cast(unsigned int,key)-1<cast(unsigned int,t->sizearray))
return&t->array[key-1];
else{
lua_Number nk=cast_num(key);
Expand Down

0 comments on commit cf3e01e

Please sign in to comment.