Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/Area.py
diff options
context:
space:
mode:
authorGonzalo Odiard <godiard@gmail.com>2012-12-18 19:45:57 (GMT)
committer Gonzalo Odiard <godiard@gmail.com>2012-12-19 18:35:21 (GMT)
commit75854b56f534ddcf3f5418e5a747f699c11c3944 (patch)
treea7f5206c427f8a0cf3dc0b380724d66873efc56e /Area.py
parentf88201e7622c14bcaaea0426ddc3cb730509acf2 (diff)
Fix memory leak in flood_fill method - SL #4334
Important information about refcounting in python [1] and [2] Te binaries for different architectures need be recompiled. [1] http://docs.python.org/release/2.5.2/api/refcountDetails.html [2] http://edcjones.tripod.com/refcount.html Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
Diffstat (limited to 'Area.py')
-rw-r--r--Area.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Area.py b/Area.py
index 9318266..6236bb0 100644
--- a/Area.py
+++ b/Area.py
@@ -865,10 +865,12 @@ class Area(Gtk.DrawingArea):
pixels2 = fill(pixels, x, y, width, height, fill_color)
# the c implementation returns a list instead of array.array
pixels = array.array(_array_type_used, pixels2)
+ del(pixels2)
# create a updated drawing_canvas
self.drawing_canvas_data = cairo.ImageSurface.create_for_data(pixels,
cairo.FORMAT_ARGB32, width, height)
+ del(pixels)
self.setup(width, height)
self.queue_draw()