check if index is valid before pushing back value.

This commit is contained in:
Artem Pavlenko 2012-01-31 09:45:06 +00:00
parent f53122ea04
commit cad0261e55

View File

@ -143,7 +143,8 @@ public:
else
{
cont_type::size_type index = ctx_->push(key);
data_.push_back(val);
if (index == data_.size())
data_.push_back(val);
}
}