add safety check to get_slot (this appears to be part of the error andrew is getting - possibly the victim of mem corruption)

This was SVN commit r3151.
This commit is contained in:
janwas 2005-11-19 04:13:37 +00:00
parent ae7303cce4
commit 76c7f96833

View File

@ -166,6 +166,7 @@ public:
T* get_slot(Key key)
{
u32 hash = Hash(key);
debug_assert(max_entries != 0); // otherwise, mask will be incorrect
const uint mask = max_entries-1;
T* p;
for(;;)