[libreoffice/f20] Resolves: rhbz#1101224 crash, fdo#70455 .xlsx formulas
Eike Rathke
erack at fedoraproject.org
Wed May 28 09:03:05 UTC 2014
commit 33496988aeb45ede31938dad7e5100c2b66922fd
Author: Eike Rathke <erack at redhat.com>
Date: Wed May 28 11:01:12 2014 +0200
Resolves: rhbz#1101224 crash, fdo#70455 .xlsx formulas
...o-70455-B1-SOMENAME-is-not-a-valid-single.patch | 86 ++++++++++++++++++++
...bz-1101224-do-not-attempt-to-obtain-names.patch | 56 +++++++++++++
libreoffice.spec | 6 +-
3 files changed, 147 insertions(+), 1 deletions(-)
---
diff --git a/0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch b/0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch
new file mode 100644
index 0000000..cb688b5
--- /dev/null
+++ b/0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch
@@ -0,0 +1,86 @@
+From 999bf6dc080d69356e96bcdb6512493486698255 Mon Sep 17 00:00:00 2001
+Message-Id: <999bf6dc080d69356e96bcdb6512493486698255.1401226654.git.erack at redhat.com>
+From: Eike Rathke <erack at redhat.com>
+Date: Tue, 27 May 2014 23:19:36 +0200
+Subject: [PATCH] resolved fdo#70455 B1:SOMENAME is not a valid singleton
+ reference
+MIME-Version: 1.0
+Content-Type: multipart/mixed; boundary="------------erAck-patch-parts"
+
+This is a multi-part message in MIME format.
+--------------erAck-patch-parts
+Content-Type: text/plain; charset=UTF-8; format=fixed
+Content-Transfer-Encoding: 8bit
+
+
+(cherry picked from commit ac8532ce26e79453b3a969b956ebb7823c455131)
+
+Conflicts:
+ sc/source/core/tool/address.cxx
+
+Change-Id: Iac80d74a9ec6382a232fdc2f4b798e57dc643ad3
+---
+ sc/source/core/tool/address.cxx | 21 +++++++++++++++------
+ 1 file changed, 15 insertions(+), 6 deletions(-)
+
+
+--------------erAck-patch-parts
+Content-Type: text/x-patch; name="0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch"
+Content-Transfer-Encoding: 8bit
+Content-Disposition: attachment; filename="0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch"
+
+diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
+index 3ed6213..23bca38 100644
+--- a/sc/source/core/tool/address.cxx
++++ b/sc/source/core/tool/address.cxx
+@@ -876,6 +876,14 @@ lcl_a1_get_row( const sal_Unicode* p, ScAddress* pAddr, sal_uInt16* nFlags )
+ return pEnd;
+ }
+
++/// B:B or 2:2, but not B:2 or 2:B or B2:B or B:B2 or ...
++static bool isValidSingleton( sal_uInt16 nFlags, sal_uInt16 nFlags2 )
++{
++ bool bCols = (nFlags & SCA_VALID_COL) && ((nFlags & SCA_VALID_COL2) || (nFlags2 & SCA_VALID_COL));
++ bool bRows = (nFlags & SCA_VALID_ROW) && ((nFlags & SCA_VALID_ROW2) || (nFlags2 & SCA_VALID_ROW));
++ return (bCols && !bRows) || (!bCols && bRows);
++}
++
+ static sal_uInt16
+ lcl_ScRange_Parse_XL_A1( ScRange& r,
+ const sal_Unicode* p,
+@@ -982,7 +990,7 @@ lcl_ScRange_Parse_XL_A1( ScRange& r,
+ }
+
+ p = tmp2;
+- p = lcl_eatWhiteSpace( p+1 );
++ p = lcl_eatWhiteSpace( p+1 ); // after ':'
+ tmp1 = lcl_a1_get_col( p, &r.aEnd, &nFlags2 );
+ if( !tmp1 && aEndTabName.isEmpty() ) // Probably the aEndTabName was specified after the first range
+ {
+@@ -995,16 +1003,17 @@ lcl_ScRange_Parse_XL_A1( ScRange& r,
+ r.aEnd.SetTab( nTab );
+ nFlags |= SCA_VALID_TAB2 | SCA_TAB2_3D | SCA_TAB2_ABSOLUTE;
+ }
+- p = lcl_eatWhiteSpace( p+1 );
++ if (*p == '!' || *p == ':')
++ p = lcl_eatWhiteSpace( p+1 );
+ tmp1 = lcl_a1_get_col( p, &r.aEnd, &nFlags2 );
+ }
+ }
+- if( !tmp1 ) // strange, but valid singleton
+- return nFlags;
++ if( !tmp1 ) // strange, but maybe valid singleton
++ return isValidSingleton( nFlags, nFlags2) ? nFlags : (nFlags & ~SCA_VALID);
+
+ tmp2 = lcl_a1_get_row( tmp1, &r.aEnd, &nFlags2 );
+- if( !tmp2 ) // strange, but valid singleton
+- return nFlags;
++ if( !tmp2 ) // strange, but maybe valid singleton
++ return isValidSingleton( nFlags, nFlags2) ? nFlags : (nFlags & ~SCA_VALID);
+
+ if ( *tmp2 != 0 )
+ {
+
+--------------erAck-patch-parts--
+
+
diff --git a/0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch b/0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch
new file mode 100644
index 0000000..8dbad10
--- /dev/null
+++ b/0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch
@@ -0,0 +1,56 @@
+From 8ce7b5072123fc9b1a0ef4ee640cc0f86d37283f Mon Sep 17 00:00:00 2001
+Message-Id: <8ce7b5072123fc9b1a0ef4ee640cc0f86d37283f.1401266493.git.erack at redhat.com>
+From: Eike Rathke <erack at redhat.com>
+Date: Tue, 27 May 2014 12:31:30 +0200
+Subject: [PATCH] resolved rhbz#1101224 do not attempt to obtain names for NULL
+ tabs
+MIME-Version: 1.0
+Content-Type: multipart/mixed; boundary="------------erAck-patch-parts"
+
+This is a multi-part message in MIME format.
+--------------erAck-patch-parts
+Content-Type: text/plain; charset=UTF-8; format=fixed
+Content-Transfer-Encoding: 8bit
+
+
+This happened when the HTML export via clipboard tried to resolve
+conditional formats, where we have a temporary instance of a document
+containing only the sheet to be exported.
+
+Change-Id: Ic7498a1cab3eabede74773868287a2cc3edef052
+(cherry picked from commit 17979abf4fde202cae231be19a218be3fe27d04c)
+---
+ sc/source/core/data/document.cxx | 9 +++++++--
+ 1 file changed, 7 insertions(+), 2 deletions(-)
+
+
+--------------erAck-patch-parts
+Content-Type: text/x-patch; name="0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch"
+Content-Transfer-Encoding: 8bit
+Content-Disposition: attachment; filename="0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch"
+
+diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
+index 47164be..2ec7d68 100644
+--- a/sc/source/core/data/document.cxx
++++ b/sc/source/core/data/document.cxx
+@@ -259,9 +259,14 @@ std::vector<OUString> ScDocument::GetAllTableNames() const
+ TableContainer::const_iterator it = maTabs.begin(), itEnd = maTabs.end();
+ for (; it != itEnd; ++it)
+ {
++ // Positions need to be preserved for ScCompiler and address convention
++ // context, so still push an empty string for NULL tabs.
+ OUString aName;
+- const ScTable& rTab = **it;
+- rTab.GetName(aName);
++ if (*it)
++ {
++ const ScTable& rTab = **it;
++ rTab.GetName(aName);
++ }
+ aNames.push_back(aName);
+ }
+
+
+--------------erAck-patch-parts--
+
+
diff --git a/libreoffice.spec b/libreoffice.spec
index b76ddcd..f55a86f 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -313,6 +313,8 @@ Patch55: 0002-coverity-SfxBaseModel-s-pImpl-of-fallback-TargetDocu.patch
Patch56: 0001-strangely-obvious-leaky-code.patch
Patch57: 0001-various-situations-where-graphic-go-missing-on-save.patch
Patch58: 0001-fdo-78536-sfx2-template-dialog-make-the-am-i-dead-ye.patch
+Patch59: 0001-resolved-rhbz-1101224-do-not-attempt-to-obtain-names.patch
+Patch60: 0001-resolved-fdo-70455-B1-SOMENAME-is-not-a-valid-single.patch
%define instdir %{_libdir}
%define baseinstdir %{instdir}/libreoffice
@@ -2276,8 +2278,10 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
%endif
%changelog
-* Fri May 23 2014 Caolán McNamara <caolanm at redhat.com> - 1:4.2.4.2-16.UNBUILT
+* Wed May 28 2014 Eike Rathke <erack at redhat.com> - 1:4.2.4.2-16
- Resolves: rhbz#1100357 crash after closing style dialog
+- Resolves: rhbz#1101224 crash when clipboard-copying a sheet to HTML
+- Resolves: fdo#70455 loading .xlsx some formulas with range operator are corrupted
* Fri May 23 2014 Caolán McNamara <caolanm at redhat.com> - 1:4.2.4.2-15
- Resolves: rhbz#1084822 graphics missing after save and reload
More information about the scm-commits
mailing list