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 353189 - gnome-typing-monitor leaks memory on each screen capture
gnome-typing-monitor leaks memory on each screen capture
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: [obsolete] Typing break
2.15.x
Other Linux
: Normal normal
: ---
Assigned To: Richard Hult
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2006-08-28 08:16 UTC by Daniel Holbach
Modified: 2006-10-04 20:11 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Daniel Holbach 2006-08-28 08:16:19 UTC
Forwarded from: https://launchpad.net/distros/ubuntu/+source/control-center/+bug/57704

Each time gnome-typing-monitor says "Take a break!", it does a screen capture.
And each time it does a screen capture, it leaks memory. I know this because valgrind told me:

==3394== 178,200 bytes in 253 blocks are possibly lost in loss record 174 of 176
==3394== at 0x401F548: memalign (vg_replace_malloc.c:332)
==3394== by 0x401F5A2: posix_memalign (vg_replace_malloc.c:386)
==3394== by 0x456720C: (within /usr/lib/libglib-2.0.so.0.1200.2)
==3394== by 0x4567CA3: g_slice_alloc (in /usr/lib/libglib-2.0.so.0.1200.2)
==3394== by 0x4567DDD: g_slice_alloc0 (in /usr/lib/libglib-2.0.so.0.1200.2)
==3394== by 0x44F0015: g_type_create_instance (in /usr/lib/libgobject-2.0.so.0.1200.2)
==3394== by 0x44D72C0: (within /usr/lib/libgobject-2.0.so.0.1200.2)
==3394== by 0x44D588D: g_object_newv (in /usr/lib/libgobject-2.0.so.0.1200.2)
==3394== by 0x44D63C6: g_object_new_valist (in /usr/lib/libgobject-2.0.so.0.1200.2)
==3394== by 0x44D64C6: g_object_new (in /usr/lib/libgobject-2.0.so.0.1200.2)
==3394== by 0x4485A73: gdk_pixbuf_new_from_data (in /usr/lib/libgdk_pixbuf-2.0.so.0.1000.1)
==3394== by 0x4483F4C: gdk_pixbuf_copy (in /usr/lib/libgdk_pixbuf-2.0.so.0.1000.1)

Reproduction steps:
1. Open top and sort by memory usage. Note the usage for gnome-typing-monitor.
2. Tell gnome-typing-monitor to "Take a break"
3. Postpone the break.
4. Repeat steps 2 and 3 a couple of times.
5. Note the memory usage for gnome-typing-monitor.

Expected results:
gnome-typing-monitor does not take up significantly more memory each time.

Actual results:
It grows by a few megabytes each time it greys out the screen.
Comment 1 Richard Hult 2006-08-28 08:20:27 UTC
Are you sure it's not the status icon blinking you're seeing? GTK+ had a memory leak that would make all the icons leak when blinking it, it has been fixed in GTK+ CVS but not released yet iirc.
Comment 2 Richard Hult 2006-08-28 08:28:46 UTC
I'm talking about http://bugzilla.gnome.org/show_bug.cgi?id=352264

Comment 3 Simon Law 2006-08-28 23:09:27 UTC
I'm fairly sure it's not.  I manually trigger "Take a break" and it leaks at that
point.
Comment 4 Richard Hult 2006-08-29 06:50:47 UTC
I'm not convinced though, since that code hasn't changed and if there was a leak like that, it should have been noticed several years ago... could you please re-run valgrind with a larger backtrace (--num-callers=20 or so)?
Comment 5 Simon Law 2006-10-04 18:51:01 UTC
I can no longer reproduce this problem, so I suppose that it _was_ the GTK+ bug.
Comment 6 Sebastien Bacher 2006-10-04 20:11:05 UTC
marking as fixed then