[gtk/inscription-leak-fixes: 2/2] inscription: Plug a memory leak
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/inscription-leak-fixes: 2/2] inscription: Plug a memory leak
- Date: Sat, 13 Aug 2022 00:35:48 +0000 (UTC)
commit 33cf8f9404666f1eb2e9522ef12ca0ecd41e0108
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Aug 12 20:02:58 2022 -0400
inscription: Plug a memory leak
PangoFontMetrics also need to be freed.
gtk/gtkinscription.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gtk/gtkinscription.c b/gtk/gtkinscription.c
index edad5f7ac9..7ce22702eb 100644
--- a/gtk/gtkinscription.c
+++ b/gtk/gtkinscription.c
@@ -344,9 +344,9 @@ get_line_pixels (GtkInscription *self,
int ascent, descent;
metrics = gtk_inscription_get_font_metrics (self);
-
ascent = pango_font_metrics_get_ascent (metrics);
descent = pango_font_metrics_get_descent (metrics);
+ pango_font_metrics_unref (metrics);
if (baseline)
*baseline = ascent;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]