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..5dda9e3 --- /dev/null +++ b/0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch @@ -0,0 +1,58 @@ +From 7b2cb8d2588211af8fd7c91367599b0fe946c9c9 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 7d8b45e..25e8bcd 100644 +--- a/vcl/inc/unx/salinst.h ++++ b/vcl/inc/unx/salinst.h +@@ -37,11 +37,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< rtl::OUString, boost::unordered_map< Atom, com::sun::star::uno::Reference< com::sun::star::datatransfer::clipboard::XClipboard > >, rtl::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 175db95..1085401 100644 +--- a/vcl/unx/generic/dtrans/X11_service.cxx ++++ b/vcl/unx/generic/dtrans/X11_service.cxx +@@ -77,8 +77,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 251bb63..e99370f 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -260,6 +260,7 @@ Patch38: 0001-Resolves-rhbz-949238-div-by-zero-on-pagedown-in-0-wi.patch Patch39: 0001-valgrind-uninitialized-value.patch Patch40: 0001-Resolves-fdo-47209-and-rhbz-927223-syntax-highlighte.patch Patch41: 0001-rhbz-867808-Do-not-throw-RuntimeException-by-pointer.patch +Patch42: 0001-rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} %define instdir %{_libdir} @@ -1013,6 +1014,7 @@ mv -f redhat.soc extras/source/palettes/standard.soc %patch39 -p1 -b .valgrind-uninitialized-value.patch %patch40 -p1 -b .fdo-47209-and-rhbz-927223-syntax-highlighte.patch %patch41 -p1 -b .rhbz-867808-Do-not-throw-RuntimeException-by-pointer.patch +%patch42 -p1 -b .rhbz-954991-Avoid-static-data-causing-trouble-at-exi.patch # TODO: check this # these are horribly incomplete--empty translations and copied english @@ -2282,8 +2284,9 @@ update-desktop-database %{_datadir}/applications &> /dev/null || : %endif %changelog -* Tue Apr 16 2013 Stephan Bergmann - 1:3.6.6.2-4-UNBUILT +* Mon Apr 22 2013 Stephan Bergmann - 1:3.6.6.2-4-UNBUILT - Resolves: rhbz#867808 do not throw UNO exceptions by pointer in C++ +- Resolves: rhbz#954991 Avoid static data (causing trouble at exit) * Tue Apr 16 2013 Caolán McNamara - 1:3.6.6.2-3 - Related: rhbz#924515 uninitialized variable in editengine