Ugly hack to fix a memory corruption problem

This commit is contained in:
fredb
2008-12-06 23:01:24 +00:00
parent b601cdb6a5
commit b38e6d8bf3

View File

@@ -98,7 +98,7 @@ static int recsize(int lgsz)
{
HashRec hr;
hr.lgsz = lgsz;
return (int)((char*)&TAB(&hr)[POW2(lgsz+1)] - (char*)&hr);
return (int)((char*)&TAB(&hr)[POW2(lgsz+1)] - (char*)&hr) + sizeof(naRef);
}
static HashRec* resize(struct naHash* hash)