[mutter/gnome-3-34] backends: Plug MetaKmsPageFlipData leak
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/gnome-3-34] backends: Plug MetaKmsPageFlipData leak
- Date: Tue, 12 Nov 2019 12:41:11 +0000 (UTC)
commit cc00e55513c4e9a086dba2909380312bcb9f64a9
Author: Carlos Garnacho <carlosg gnome org>
Date: Mon Oct 21 18:55:12 2019 +0200
backends: Plug MetaKmsPageFlipData leak
If the page flip is postponed, keep a ref to it, but still unref it
on the page flip callback anyways. Fix suggested by Jonas Ã…dahl.
(cherry-picked from 668be1f4bd309fedc846a0022180aef5a9e44869)
https://gitlab.gnome.org/GNOME/mutter/merge_requests/873
src/backends/native/meta-kms-impl-simple.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/backends/native/meta-kms-impl-simple.c b/src/backends/native/meta-kms-impl-simple.c
index 19c4b2b33..571dccf12 100644
--- a/src/backends/native/meta-kms-impl-simple.c
+++ b/src/backends/native/meta-kms-impl-simple.c
@@ -772,12 +772,14 @@ meta_kms_impl_simple_handle_page_flip_callback (MetaKmsImpl *impl,
{
impl_simple->postponed_page_flip_datas =
g_list_append (impl_simple->postponed_page_flip_datas,
- page_flip_data);
+ meta_kms_page_flip_data_ref (page_flip_data));
}
else
{
meta_kms_page_flip_data_flipped_in_impl (page_flip_data);
}
+
+ meta_kms_page_flip_data_unref (page_flip_data);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]