Bug 222260

Summary: gtk2 leaks memory on expose
Product: [Fedora] Fedora Reporter: Davyd <davyd>
Component: gtk2Assignee: Matthias Clasen <mclasen>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: medium    
Version: 6CC: idht4n, tonynelson
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-02-02 21:31:38 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
testcase to demonstrate leak, compile with gcc -g -o gtk_rc_style_test `pkg-config --cflags --libs gtk+-2.0` gtk_rc_style_test.c
none
valgrind log from one of my tests none

Description Davyd 2007-01-11 07:23:24 UTC
Fedora gtk2-2.10.4-10 seems to leak memory on redraws (eg. modify_bg or expose),
at least for GtkButtons. This is not present in gtk2-2.10.4-6, I have not tested
any versions in between.

I have prepared a testcase that exposes a button every 50ms (or changes a button
background colour, which is how I first noticed the problem).

I could not track down what changed between -6 and -10 to cause this leak to
appear. It definitely exists on both i386 and amd64.

I'm wondering if this is related to bug 220903, but the valgrind log doesn't
have full leak checking.

Comment 1 Davyd 2007-01-11 07:23:25 UTC
Created attachment 145319 [details]
testcase to demonstrate leak, compile with gcc -g -o gtk_rc_style_test `pkg-config --cflags --libs gtk+-2.0` gtk_rc_style_test.c

Comment 2 Davyd 2007-01-11 07:27:03 UTC
Created attachment 145320 [details]
valgrind log from one of my tests

Comment 3 Tony Nelson 2007-01-12 16:36:17 UTC
gtk2-2.10.4-10.fc6.i386 has several leaks that are fixed in 2.10.7 upstream and
in rawhide, according to the changelog.  I noticed a leak when setting a
statusbar's text a few million times (used over 500 MB memory), and that
replacing the statusbar with a label did the same.  This was in Python, so I
wrote a trivial GTK program in C, which leaked the same way.  Linking that
program against a libgtk built from rawhide fixes that leak.

RFE gtk2 2.10.7 as in rawhide?

Comment 4 Matthias Clasen 2007-01-12 16:49:04 UTC
No, 2.10.7 has other issues. I'll do a 2.10.8 early next week, that will
hopefully find its way into fc6-updates

Comment 5 Tony Nelson 2007-01-12 16:54:06 UTC
OK.  That's why I didn't make the request as a separate RFE.  I certainly didn't
test anything else with 2.10.7.

Comment 6 Matthias Clasen 2007-02-02 21:29:14 UTC
*** Bug 220903 has been marked as a duplicate of this bug. ***

Comment 7 Matthias Clasen 2007-02-02 21:31:38 UTC
2.10.8 is in FC-6 updates now and should resolve this issue.