[libreoffice/f20] Resolves: rhbz#1167683 crash in SwPostItMgr::HasNotes

Caolán McNamara caolanm at fedoraproject.org
Fri Nov 28 11:00:49 UTC 2014


commit 49938bf16f098fe526f31b5898e2b5f1b6f5b2a2
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Nov 28 11:00:25 2014 +0000

    Resolves: rhbz#1167683 crash in SwPostItMgr::HasNotes

 0001-Prevent-occasional-crash.patch |   33 +++++++++++++++++++++++++++++++++
 libreoffice.spec                    |    5 ++++-
 2 files changed, 37 insertions(+), 1 deletions(-)
---
diff --git a/0001-Prevent-occasional-crash.patch b/0001-Prevent-occasional-crash.patch
new file mode 100644
index 0000000..46e919f
--- /dev/null
+++ b/0001-Prevent-occasional-crash.patch
@@ -0,0 +1,33 @@
+From 66149c4212a3bf124807843f3cdaac1ad4e078e7 Mon Sep 17 00:00:00 2001
+From: Tor Lillqvist <tml at collabora.com>
+Date: Fri, 20 Dec 2013 14:56:33 +0200
+Subject: [PATCH] Prevent occasional crash
+
+I came across the crash by accident when checking how it works to have
+multiple windows showing the same document. Pasting in lots of text
+and then quickly telling LO to exit with Cmd-Q caused a crash here as
+GetPostItMgr() returned NULL.
+
+Change-Id: Ib9e636df0832a679a1d81fa3856ea0a7105a69c3
+(cherry picked from commit 0eb1ef39084a978e8c2bec977ebabf6708f0c073)
+---
+ sw/source/ui/misc/swruler.cxx | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/sw/source/ui/misc/swruler.cxx b/sw/source/ui/misc/swruler.cxx
+index fa396d0..b1035c9 100644
+--- a/sw/source/ui/misc/swruler.cxx
++++ b/sw/source/ui/misc/swruler.cxx
+@@ -56,7 +56,8 @@ void SwCommentRuler::Paint( const Rectangle& rRect )
+ {
+     SvxRuler::Paint( rRect );
+     // Don't draw if there is not any note
+-    if ( mpViewShell->GetPostItMgr()->HasNotes() )
++    if ( mpViewShell->GetPostItMgr()
++         && mpViewShell->GetPostItMgr()->HasNotes() )
+         DrawCommentControl();
+ }
+ 
+-- 
+1.9.3
+
diff --git a/libreoffice.spec b/libreoffice.spec
index 07f8203..3d4169e 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -36,7 +36,7 @@ Summary:        Free Software Productivity Suite
 Name:           libreoffice
 Epoch:          1
 Version:        %{libo_version}.2
-Release:        11%{?libo_prerelease}%{?dist}
+Release:        12%{?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.libreoffice.org/
@@ -2275,6 +2275,9 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
 %endif
 
 %changelog
+* Fri Nov 28 2014 Caolán McNamara <caolanm at redhat.com> - 1:4.2.7.2-12.unbuilt
+- Resolves: rhbz#1167683 crash in SwPostItMgr::HasNotes
+
 * Thu Nov 27 2014 Caolán McNamara <caolanm at redhat.com> - 1:4.2.7.2-11
 - Resolves: fdo#84043 don't create duplicate Mirrored props
 - Resolves: rhbz#1165444 abrt crash with NULL pView


More information about the scm-commits mailing list