After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 789432 - GHashTable tries to resize when size reaches 2^29
GHashTable tries to resize when size reaches 2^29
Status: RESOLVED DUPLICATE of bug 694501
Product: glib
Classification: Platform
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2017-10-24 19:21 UTC by iosipos.mpekenmpaouer
Modified: 2017-10-25 09:37 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description iosipos.mpekenmpaouer 2017-10-24 19:21:36 UTC
When the hashtable size (nnodes) reaches 2^29 an integer overflow occurs in function g_hash_table_maybe_resize so that condition "size > hash_table->nnodes * 4" becomes true and g_hash_table_resize is called, requesting an absurd size of memory. e.g.:

GLib-ERROR **: /build/glib2.0-y6934K/glib2.0-2.42.1/./glib/gmem.c:353: overflow allocating 18446744071562067968*8 bytes
Trace/breakpoint trap
Comment 1 Philip Withnall 2017-10-25 09:37:06 UTC
Duplicate of bug #694501.

*** This bug has been marked as a duplicate of bug 694501 ***