summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorArul Michael <arul71.m@gmail.com>2016-03-31 17:17:58 +0530
committerEike Rathke <erack@redhat.com>2016-03-31 15:49:34 +0000
commit7a9a28857a4da8d2353c88ce90d8a60030d89e48 (patch)
tree70f44163c589b5f81b14f391f69da49c575ea0c0 /sc
parent4ab36bbd1816d6f297892a638e6826f28ca87150 (diff)
tdf#92963 Pasting a whole row with data crashes all open LibO apps
In ScColumn::GetNeededSize the memory pointed by rOptions.pPattern is freed and new value is set again in ScFormulaCell::InterpretTail function in pDocument->SetNumberFormat when pDocument->GetCondResult is called in column2.cxx:130.For fix setting the newly calculated ScPatternAttr* value after the GetCondResult call. Change-Id: I045404465b6dfa561b0821bb3b1875463aa7887a Reviewed-on: https://gerrit.libreoffice.org/23688 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com> (cherry picked from commit 99bf0b931401f556033f67297aa9783c4cf19b00) Reviewed-on: https://gerrit.libreoffice.org/23708
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/column2.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx
index 01dde573414e..8c15aaebbf63 100644
--- a/sc/source/core/data/column2.cxx
+++ b/sc/source/core/data/column2.cxx
@@ -129,6 +129,13 @@ long ScColumn::GetNeededSize(
// conditional formatting
const SfxItemSet* pCondSet = pDocument->GetCondResult( nCol, nRow, nTab );
+ //The pPattern may change in GetCondResult
+ if (aCell.meType == CELLTYPE_FORMULA)
+ {
+ pPattern = pAttrArray->GetPattern( nRow );
+ if (ppPatternChange)
+ *ppPatternChange = pPattern;
+ }
// line break?
const SfxPoolItem* pCondItem;