Blame SOURCES/0001-lp-1566050-prevent-cyclic-reference-zombies.patch

606fae
From 25b8bcab289f13cab6c0a154a0c32ab19de2ef21 Mon Sep 17 00:00:00 2001
606fae
From: Bjoern Michaelsen <bjoern.michaelsen@canonical.com>
606fae
Date: Tue, 12 Apr 2016 12:20:07 +0200
606fae
Subject: [PATCH] lp#1566050: prevent cyclic reference zombies
606fae
606fae
regression, likely from 2660d24a07866e083c5135ea263030f3e3a2e729:
606fae
606fae
1/ Since that change mxAccessible in ScCsvGrid holds a rtl::Reference on
606fae
a ScAccessibleCsvGrid
606fae
2/ Which in turn holds a VclPtr<> (aka a rtl::Reference with lipstick)
606fae
on the ScCsvControl
606fae
606fae
These are a circular references, making both of them live forever and
606fae
leak past the point where on LibreOffice close all of Vcl is long gone,
606fae
when these are dtored. Clearing mxAccessible on disposing should help.
606fae
606fae
Change-Id: Iebb2635ec4ea143e7f0dbfebad2e6141a68e72e8
606fae
Reviewed-on: https://gerrit.libreoffice.org/24020
606fae
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
606fae
Tested-by: Noel Grandin <noelgrandin@gmail.com>
606fae
(cherry picked from commit 941e891d16853e5eff3e40cf48cdafb3146b2750)
606fae
---
606fae
 sc/source/ui/dbgui/csvcontrol.cxx | 1 +
606fae
 1 file changed, 1 insertion(+)
606fae
606fae
diff --git a/sc/source/ui/dbgui/csvcontrol.cxx b/sc/source/ui/dbgui/csvcontrol.cxx
606fae
index b53b5bc..7449192 100644
606fae
--- a/sc/source/ui/dbgui/csvcontrol.cxx
606fae
+++ b/sc/source/ui/dbgui/csvcontrol.cxx
606fae
@@ -81,6 +81,7 @@ void ScCsvControl::dispose()
606fae
 {
606fae
     if( mxAccessible.is() )
606fae
         mxAccessible->dispose();
606fae
+    mxAccessible = nullptr; // lp#1566050: prevent cyclic reference zombies
606fae
     Control::dispose();
606fae
 }
606fae
 
606fae
-- 
606fae
2.9.3
606fae