From 66cd725b5f386d48252a620fb58415ddb65388ef Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 18 Dec 2017 15:24:58 +0100 Subject: Don't leak SvtSaveOptions instance through ItemHolder1::holdConfigItem MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ...where ItemHolder1 apparently leaks the items ever since > commit ef2c49c9a5788e35249d8d5406a09c84ecd062ee > Author: RĂ¼diger Timm > Date: Fri Nov 11 07:50:10 2005 +0000 > > INTEGRATION: CWS perform06 (1.6.60); FILE MERGED > 2005/11/07 13:32:40 as 1.6.60.2: #i56589# dont cache GlobalEventConfig() inside ItemHolder1^... combination of static pointer and WeakImplHelper cant not work > 2005/10/25 08:04:02 as 1.6.60.1: #i56589# hold config items alive till office die That started to cause problems when 78a6ce17f06fbe13b806fd563e85a4fe60d3bcfc "DELETEZ->std::unique_ptr in toolkit,unotools" now stopped to leak the global static std::unique_ptr pOptions; in unotools/source/config/saveopt.cxx when any SvtSaveOptions instances are leaked, so that at least PythonTest_pyuno_pytests_testcollections started to fail in ASan builds now when that global pOptions is destroyed at exit. I don't see a good reason for that ItemHolder1::holdConfigItem stuff here, so lets try and drop it from SvtSaveOptions at least. Change-Id: I6d44708fc4e2e5dfafaa9bfe8f3fa2f854ae0952 Reviewed-on: https://gerrit.libreoffice.org/46726 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- include/unotools/itemholderbase.hxx | 1 - 1 file changed, 1 deletion(-) (limited to 'include/unotools') diff --git a/include/unotools/itemholderbase.hxx b/include/unotools/itemholderbase.hxx index 9cb50417c163..94c20059abf9 100644 --- a/include/unotools/itemholderbase.hxx +++ b/include/unotools/itemholderbase.hxx @@ -66,7 +66,6 @@ enum class EItem PrintFileOptions , // 2 PrintWarningOptions , - SaveOptions , SecurityOptions , SysLocaleOptions , // 2 -- cgit