From 5fc3bb80d118670decf5855a9d0a280254805d7b Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 22 Apr 2013 17:55:18 +0200 Subject: [PATCH] Resolves: rhbz#954991 Avoid static data (causing trouble at exit) --- ...d-static-data-causing-trouble-at-exi.patch | 58 +++++++++++++++++++ libreoffice.spec | 7 ++- 2 files changed, 64 insertions(+), 1 deletion(-) create mode 100644 0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch diff --git a/0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch b/0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch new file mode 100644 index 0000000..4b97d4a --- /dev/null +++ b/0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch @@ -0,0 +1,58 @@ +From ddd2de79573ab9eee065c21a5657c8a065a05d57 Mon Sep 17 00:00:00 2001 +From: Stephan Bergmann +Date: Mon, 22 Apr 2013 16:21:57 +0200 +Subject: [PATCH] rhbz#954991 Avoid static data (causing trouble at exit) + +(cherry picked from commit aa1aedb2a0ef97cb6110f18a1de86abc8dbcd304) +Conflicts: + vcl/inc/unx/salinst.h + vcl/unx/generic/dtrans/X11_service.cxx + +Change-Id: Ifc8275276811ba24b62f93096e7cb98a5dbf658c +--- + vcl/inc/unx/salinst.h | 10 ++++++++++ + vcl/unx/generic/dtrans/X11_service.cxx | 2 -- + 2 files changed, 10 insertions(+), 2 deletions(-) + +diff --git a/vcl/inc/unx/salinst.h b/vcl/inc/unx/salinst.h +index 83ba4b8..ea997d6 100644 +--- a/vcl/inc/unx/salinst.h ++++ b/vcl/inc/unx/salinst.h +@@ -27,11 +27,21 @@ + #include + #include "generic/geninst.h" + ++#include ++#include ++#include ++ ++namespace com { namespace sun { namespace star { namespace datatransfer { ++ namespace clipboard { class XClipboard; } ++} } } } + + // -=-= SalInstanceData =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= + class SalXLib; + class VCLPLUG_GEN_PUBLIC X11SalInstance : public SalGenericInstance + { ++private: ++ boost::unordered_map< OUString, boost::unordered_map< Atom, com::sun::star::uno::Reference< com::sun::star::datatransfer::clipboard::XClipboard > >, OUStringHash > m_aInstances; ++ + protected: + SalXLib *mpXLib; + public: +diff --git a/vcl/unx/generic/dtrans/X11_service.cxx b/vcl/unx/generic/dtrans/X11_service.cxx +index dc2ff17..5d4ac5e 100644 +--- a/vcl/unx/generic/dtrans/X11_service.cxx ++++ b/vcl/unx/generic/dtrans/X11_service.cxx +@@ -62,8 +62,6 @@ Sequence< OUString > SAL_CALL x11::Xdnd_dropTarget_getSupportedServiceNames() + + css::uno::Reference< XInterface > X11SalInstance::CreateClipboard( const Sequence< Any >& arguments ) + { +- static boost::unordered_map< OUString, ::boost::unordered_map< Atom, Reference< XClipboard > >, ::rtl::OUStringHash > m_aInstances; +- + OUString aDisplayName; + Atom nSelection; + +-- +1.8.1.4 + diff --git a/libreoffice.spec b/libreoffice.spec index 48fa573..acfe9b7 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -43,7 +43,7 @@ Summary: Free Software Productivity Suite Name: libreoffice Epoch: 1 Version: %{libo_version}.1 -Release: 1%{?libo_prerelease}%{?dist} +Release: 2%{?libo_prerelease}%{?dist} License: (MPLv1.1 or LGPLv3+) and LGPLv3 and LGPLv2+ and BSD and (MPLv1.1 or GPLv2 or LGPLv2 or Netscape) and Public Domain and ASL 2.0 and Artistic and MPLv2.0 Group: Applications/Productivity URL: http://www.documentfoundation.org/develop @@ -251,6 +251,7 @@ Patch21: 0001-Related-rhbz-902884-check-for-GetSelectedMasterPage-.patch Patch22: 0001-Resolves-rhbz-920697-i110881-rhbz-623191-presentatio.patch Patch23: 0001-Resolves-fdo-47209-and-rhbz-927223-syntax-highlighte.patch Patch24: 0001-rhbz-867808-Do-not-throw-RuntimeException-by-pointer.patch +Patch25: 0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch %define instdir %{_libdir} %define baseinstdir %{instdir}/libreoffice @@ -1007,6 +1008,7 @@ mv -f redhat.soc extras/source/palettes/standard.soc %patch22 -p1 -b .rhbz-920697-i110881-rhbz-623191-presentatio.patch %patch23 -p1 -b .fdo-47209-and-rhbz-927223-syntax-highlighte.patch %patch24 -p1 -b .rhbz-867808-Do-not-throw-RuntimeException-by-pointer.patch +%patch25 -p1 -b .rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch # TODO: check this # these are horribly incomplete--empty translations and copied english @@ -2080,6 +2082,9 @@ update-desktop-database %{_datadir}/applications &> /dev/null || : %endif %changelog +* Mon Apr 22 2013 Stephan Bergmann - 1:4.0.3.1-2 +- Resolves: rhbz#954991 Avoid static data (causing trouble at exit) + * Thu Apr 18 2013 David Tardon - 1:4.0.3.1-1 - 4.0.3 rc1 - Resolves: rhbz#867808 do not throw UNO exceptions by pointer in C++