[libreoffice/f15] Resolves: rhbz#759647 dispose clears mpPresTimer

Caolán McNamara caolanm at fedoraproject.org
Wed Dec 7 12:32:04 UTC 2011


commit dead736aae6477be1593d5927c4f6b47c3713595
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Dec 7 12:31:55 2011 +0000

    Resolves: rhbz#759647 dispose clears mpPresTimer

 ...bz-759647-dispose-clears-mpPresTimer-befo.patch |   34 ++++++++++++++++++++
 libreoffice.spec                                   |    8 +++-
 2 files changed, 40 insertions(+), 2 deletions(-)
---
diff --git a/0001-Resolves-rhbz-759647-dispose-clears-mpPresTimer-befo.patch b/0001-Resolves-rhbz-759647-dispose-clears-mpPresTimer-befo.patch
new file mode 100644
index 0000000..c309f44
--- /dev/null
+++ b/0001-Resolves-rhbz-759647-dispose-clears-mpPresTimer-befo.patch
@@ -0,0 +1,34 @@
+From d57887eaad534ca51fc4975918fab66b2f93633d Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolanm at redhat.com>
+Date: Tue, 6 Dec 2011 16:26:05 +0000
+Subject: [PATCH] Resolves: rhbz#759647 ::dispose clears mpPresTimer before
+ releaseTimer called
+
+---
+ slideshow/source/engine/slideshowimpl.cxx |    8 ++++++--
+ 1 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
+index 5be3b62..4277280 100644
+--- a/slideshow/source/engine/slideshowimpl.cxx
++++ b/slideshow/source/engine/slideshowimpl.cxx
+@@ -2025,10 +2025,14 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
+         //    that have zero delay.  While the timer is stopped these events
+         //    are processed in the same run.
+         {
++            //Get a shared-ptr that outlives the scope-guard which will
++            //ensure that the pointed-to-item exists in the case of a
++            //::dispose clearing mpPresTimer
++            boost::shared_ptr<canvas::tools::ElapsedTime> xTimer(mpPresTimer);
+             comphelper::ScopeGuard scopeGuard(
+                 boost::bind( &canvas::tools::ElapsedTime::releaseTimer,
+-                             boost::cref(mpPresTimer) ) );
+-            mpPresTimer->holdTimer();
++                             boost::cref(xTimer) ) );
++            xTimer->holdTimer();
+ 
+             // process queues
+             maEventQueue.process();
+-- 
+1.7.6.4
+
diff --git a/libreoffice.spec b/libreoffice.spec
index 48b99a8..6886e83 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -32,7 +32,7 @@ Summary:        Free Software Productivity Suite
 Name:           libreoffice
 Epoch:          1
 Version:        %{libo_version}.1
-Release:        1%{?dist}
+Release:        2%{?dist}
 License:        LGPLv3 and LGPLv2+ and BSD and (MPLv1.1 or GPLv2 or LGPLv2 or Netscape) and (CDDL or GPLv2) and Public Domain
 Group:          Applications/Productivity
 URL:            http://www.documentfoundation.org/develop
@@ -167,6 +167,7 @@ Patch75: 0001-let-Qt-call-XInitThreads-so-that-it-knows-it-s-been-.patch
 Patch76: gdb-pretty-printers.patch
 Patch77: 0001-gtk3-fix-cairo-canvas-crash-for-non-X-or-svp-backend.patch
 Patch78: smoketestoo_native-build.patch
+Patch79: 0001-Resolves-rhbz-759647-dispose-clears-mpPresTimer-befo.patch
 
 %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
 %define instdir %{_libdir}
@@ -884,7 +885,7 @@ mv -f redhat.soc extras/source/palettes/standard.soc
 %patch75 -p1 -b .let-Qt-call-XInitThreads-so-that-it-knows-it-s-been-.patch
 %patch76 -p1 -b .gdb-pretty-printers.patch
 %patch77 -p1 -b .gtk3-fix-cairo-canvas-crash-for-non-X-or-svp-backend.patch
-%patch78 -p1 -b .smoketestoo_native-build.patch
+%patch79 -p1 -b .rhbz759647-dispose-clears-mpPresTimer-befo.patch
 
 touch scripting/source/pyprov/delzip
 touch scripting/util/provider/beanshell/delzip
@@ -2246,6 +2247,9 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
 %{basisinstdir}/program/kde-open-url
 
 %changelog
+* Wed Dec 07 2011 Caolán McNamara <caolanm at redhat.com> 1:3.3.4.1-2.UNBUILT
+- Resolves: rhbz#759647 dispose clears mpPresTimer
+
 * Wed Nov 30 2011 David Tardon <dtardon at redhat.com> 1:3.3.4.1-1
 - Resolves: rhbz#747356 let Qt call XInitThreads
 - new upstream version 3.3.4


More information about the scm-commits mailing list