summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorMark Wielaard <mark@klomp.org>2013-06-04 22:00:45 +0200
committerCaolán McNamara <caolanm@redhat.com>2013-06-05 11:05:38 +0100
commit99afbfdad1d53d65f22a4ea22a5cee43f98a44b9 (patch)
tree9462440b097de70bc3e081f78dd0334638ce26f1 /vcl
parent29e79344add06fed1ff764a6d24036a768cb688e (diff)
Fix memory leak in SalGtkFilePicker::SalGtkFilePicker.
The result of gtk_widget_create_pango_layout should be unrefed when done. Change-Id: I46c220a933a2dac42ec21e9e2904938bc4649dbd Reviewed-on: https://gerrit.libreoffice.org/4157 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 4450d6bbd10fbf57f18912095f58c4a79b20bcb7)
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
index 88cb3de954b5..50ec20c9dca7 100644
--- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
@@ -301,6 +301,8 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< uno::XComponentContext
PangoRectangle row_height;
pango_layout_set_markup (layout, "All Files", -1);
pango_layout_get_pixel_extents (layout, NULL, &row_height);
+ g_object_unref (layout);
+
g_object_get (cell, "ypad", &ypad, (char *)NULL);
guint height = (row_height.height + 2*ypad) * 5;
gtk_widget_set_size_request (m_pFilterView, -1, height);