fixed two valgrind warnings while saving lua state
This commit is contained in:
parent
b584ef5f21
commit
223ba3078a
2 changed files with 2 additions and 2 deletions
|
@ -153,7 +153,7 @@ void lua_Save(SaveRestoreFunc saveFunc) {
|
|||
saveFunc(&tempHash->htag, sizeof(int32));
|
||||
for (i = 0; i < tempHash->nhash; i++) {
|
||||
Node *newNode = &tempHash->node[i];
|
||||
if ((newNode->val.ttype != LUA_T_NIL) && (newNode->ref.ttype != LUA_T_NIL)) {
|
||||
if ((newNode->ref.ttype != LUA_T_NIL) && (newNode->val.ttype != LUA_T_NIL)) {
|
||||
saveObjectValue(&tempHash->node[i].ref, saveFunc);
|
||||
saveObjectValue(&tempHash->node[i].val, saveFunc);
|
||||
}
|
||||
|
|
|
@ -64,7 +64,7 @@ void luaT_init (void)
|
|||
L->IMtable_size = NUM_TAGS*2;
|
||||
L->last_tag = -(NUM_TAGS-1);
|
||||
L->IMtable = luaM_newvector(L->IMtable_size, struct IM);
|
||||
for (t=L->last_tag; t<=0; t++)
|
||||
for (t=-(L->IMtable_size-1); t<=0; t++)
|
||||
init_entry(t);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue