[Bug libstdc++/55911] Segfault in unordered_map with max_load_factor > 1
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jan 9 12:16:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55911
--- Comment #3 from Jonathan Wakely <redi at gcc dot gnu.org> 2013-01-09 12:15:39 UTC ---
This is invalid if size() > bucket_count(), which is very likely:
for (size_t i = 0; i < umap.size(); i++)
{
const size_t bs = umap.bucket_size (i);
Shouldn't the loop condition be i < umap.bucket_count() instead?
More information about the Gcc-bugs
mailing list