[Libreoffice-commits] core.git: sc/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Thu Sep 17 08:49:52 UTC 2020
sc/source/core/data/column2.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit 5774c6f4bb365a690049713307481d9a63aa20a6
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Sep 15 15:48:09 2020 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Thu Sep 17 10:49:09 2020 +0200
ColumnStorageDumper ctor never called with null ScDocument*
Change-Id: I0d2e2c4b556bb6a3baba6a1fa663a48da8290cd7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102885
Tested-by: Caolán McNamara <caolanm at redhat.com>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx
index ef354cd943bf..8e209b65eeb1 100644
--- a/sc/source/core/data/column2.cxx
+++ b/sc/source/core/data/column2.cxx
@@ -1661,9 +1661,9 @@ namespace {
struct ColumnStorageDumper
{
- const ScDocument* mpDoc;
+ const ScDocument& mrDoc;
- ColumnStorageDumper( const ScDocument* pDoc ) : mpDoc(pDoc) {}
+ ColumnStorageDumper( const ScDocument& rDoc ) : mrDoc(rDoc) {}
void operator() (const sc::CellStoreType::value_type& rNode) const
{
@@ -1732,7 +1732,7 @@ struct ColumnStorageDumper
void printFormula(const ScFormulaCell* pCell) const
{
- sc::TokenStringContext aCxt(mpDoc, mpDoc->GetGrammar());
+ sc::TokenStringContext aCxt(&mrDoc, mrDoc.GetGrammar());
OUString aFormula = pCell->GetCode()->CreateString(aCxt, pCell->aPos);
cout << " * formula: " << aFormula << endl;
}
@@ -1773,7 +1773,7 @@ struct ColumnStorageDumper
void ScColumn::DumpColumnStorage() const
{
cout << "-- table: " << nTab << "; column: " << nCol << endl;
- std::for_each(maCells.begin(), maCells.end(), ColumnStorageDumper(&GetDoc()));
+ std::for_each(maCells.begin(), maCells.end(), ColumnStorageDumper(GetDoc()));
cout << "--" << endl;
}
#endif
More information about the Libreoffice-commits
mailing list