summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorIzik Eidus <ieidus@redhat.com>2010-04-05 22:57:37 +0300
committerIzik Eidus <ieidus@redhat.com>2010-04-05 22:57:37 +0300
commite1a4d91896dc06aae266b7f9238833c43463edab (patch)
tree6ade7ce133491af5a7dd5c70d6794196040440f3 /common
parent9076297d1dcb525cba39d136cc26cc5b444e199d (diff)
downloadspice-e1a4d91896dc06aae266b7f9238833c43463edab.tar.gz
spice-e1a4d91896dc06aae266b7f9238833c43463edab.tar.xz
spice-e1a4d91896dc06aae266b7f9238833c43463edab.zip
spice: common: gdi_canvas fix gdi objects leak
BitmapMask was used by the draw_text function as well therefore we need to mark from_surface = 0 if we want it to release the boject... (Was evil, took me few hours to understand from where the leak come...) Signed-off-by: Izik Eidus <ieidus@redhat.com>
Diffstat (limited to 'common')
-rw-r--r--common/gdi_canvas.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/common/gdi_canvas.c b/common/gdi_canvas.c
index 75dff69a..4362b384 100644
--- a/common/gdi_canvas.c
+++ b/common/gdi_canvas.c
@@ -918,6 +918,7 @@ static void draw_str_mask_bitmap(struct GdiCanvas *canvas,
return;
}
+ bitmap.from_surface = 0;
bitmap.cache = 0;
bitmap_data = create_bitmap(&bitmap.hbitmap, &bitmap.prev_hbitmap,
&bitmap.dc, NULL,