[pygtk] Memory leak with gdk-pixbuf and pygtk-1.99.13

2002-11-26 Thread John Fremlin

The following program eats all memory because GDK pixbufs do not seem
to be garbage collected.

I have Python 2.2 and gdk-pixbuf-0.20.0

How is it that you get away with having NULL tp_dealloc destructors on
the wrapped types? Surely that needs to be changed to typename_unref
on all types?


import gtk
import gc
import sys

def get_picture():
pixbuf = gtk.gdk.pixbuf_new_from_file("test.png")

gc.enable()
gc.set_debug(gc.DEBUG_LEAK|gc.DEBUG_STATS)
sys.stderr.write("gc thresholds %s,%s,%s\n"%gc.get_threshold())

while 1:
get_picture()

sys.stderr.write("%s junk objects out of %s, %s found\n"
 % (len(gc.garbage),len(gc.get_objects()),gc.collect())
 )


___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



[pygtk] gdk-pixbuf bindings

2001-04-17 Thread John Fremlin

Is anybody working on them? Would they be accepted into gnome-python?
-- 

http://www.penguinpowered.com/~vii
___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk