Core/DBLayer: Fix a memory leak in Field class, properly clear buffer before repopulating it.

Fixes many issues (from wrong subnames on NPCs to absent GO/Creature spawns)
Thanks to Rat for helping find the issue

--HG--
branch : trunk
This commit is contained in:
Machiavelli
2010-09-25 13:12:12 +02:00
parent 0fa7d24637
commit 477b30a1ad
3 changed files with 11 additions and 5 deletions

View File

@@ -162,7 +162,7 @@ bool ResultSet::NextRow()
}
for (uint32 i = 0; i < m_fieldCount; i++)
m_currentRow[i].SetStructuredValue(row[i], m_fields[i].type, Field::SizeForType(&m_fields[i]));
m_currentRow[i].SetStructuredValue(row[i], m_fields[i].type);
return true;
}