[gtk+] GtkImage: do not leak metrics in baseline align
- From: Paolo Borelli <pborelli src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] GtkImage: do not leak metrics in baseline align
- Date: Sat, 27 Apr 2013 11:59:41 +0000 (UTC)
commit d35596fe92f840afe13949c7d5af21623a7aa44d
Author: Paolo Borelli <pborelli gnome org>
Date: Sat Apr 27 11:08:21 2013 +0200
GtkImage: do not leak metrics in baseline align
https://bugzilla.gnome.org/show_bug.cgi?id=699020
gtk/gtkimage.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkimage.c b/gtk/gtkimage.c
index f21f227..61c41b9 100644
--- a/gtk/gtkimage.c
+++ b/gtk/gtkimage.c
@@ -1417,6 +1417,8 @@ gtk_image_get_baseline_align (GtkImage *image)
image->priv->baseline_align =
(float)pango_font_metrics_get_ascent (metrics) /
(pango_font_metrics_get_ascent (metrics) + pango_font_metrics_get_descent (metrics));
+
+ pango_font_metrics_unref (metrics);
}
return image->priv->baseline_align;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]