sc/inc/address.hxx | 2 +- sc/source/core/tool/address.cxx | 10 +++++----- sc/source/ui/vba/vbarange.cxx | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-)
New commits: commit d4ceea4ca9d9abb47a6f84da138c2918bc7100e0 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Sun Sep 13 14:37:24 2020 +0100 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Sun Sep 13 17:57:09 2020 +0200 ParseRows never passed a null ScDocument* Change-Id: Id9eb2c87ebe583f2024d5b8d8d6fd496dc90c7c7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102582 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/sc/inc/address.hxx b/sc/inc/address.hxx index 19077f4653bf..772cd7112cff 100644 --- a/sc/inc/address.hxx +++ b/sc/inc/address.hxx @@ -562,7 +562,7 @@ public: SC_DLLPUBLIC ScRefFlags ParseCols( const ScDocument* pDoc, const OUString&, const ScAddress::Details& rDetails = ScAddress::detailsOOOa1 ); - SC_DLLPUBLIC void ParseRows( const ScDocument* pDoc, + SC_DLLPUBLIC void ParseRows( const ScDocument& rDoc, const OUString&, const ScAddress::Details& rDetails = ScAddress::detailsOOOa1 ); diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx index 39bae2ea485c..0d432a795305 100644 --- a/sc/source/core/tool/address.cxx +++ b/sc/source/core/tool/address.cxx @@ -1844,7 +1844,7 @@ ScRefFlags ScRange::ParseCols( const ScDocument* pDoc, } // Parse only full row references -void ScRange::ParseRows( const ScDocument* pDoc, +void ScRange::ParseRows( const ScDocument& rDoc, const OUString& rStr, const ScAddress::Details& rDetails ) { @@ -1860,11 +1860,11 @@ void ScRange::ParseRows( const ScDocument* pDoc, case formula::FormulaGrammar::CONV_OOO: // No full row refs in OOO yet, assume XL notation case formula::FormulaGrammar::CONV_XL_A1: case formula::FormulaGrammar::CONV_XL_OOX: - if (nullptr != (p = lcl_a1_get_row( pDoc, p, &aStart, &ignored, nullptr) ) ) + if (nullptr != (p = lcl_a1_get_row( &rDoc, p, &aStart, &ignored, nullptr) ) ) { if( p[0] == ':') { - lcl_a1_get_row( pDoc, p+1, &aEnd, &ignored, nullptr); + lcl_a1_get_row( &rDoc, p+1, &aEnd, &ignored, nullptr); } else { @@ -1875,13 +1875,13 @@ void ScRange::ParseRows( const ScDocument* pDoc, case formula::FormulaGrammar::CONV_XL_R1C1: if ((p[0] == 'R' || p[0] == 'r') && - nullptr != (p = lcl_r1c1_get_row( pDoc->GetSheetLimits(), p, rDetails, &aStart, &ignored ))) + nullptr != (p = lcl_r1c1_get_row( rDoc.GetSheetLimits(), p, rDetails, &aStart, &ignored ))) { if( p[0] == ':') { if( p[1] == 'R' || p[1] == 'r' ) { - lcl_r1c1_get_row( pDoc->GetSheetLimits(), p+1, rDetails, &aEnd, &ignored ); + lcl_r1c1_get_row( rDoc.GetSheetLimits(), p+1, rDetails, &aEnd, &ignored ); } } else diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx index 37c40d7f5c13..e646b60c681f 100644 --- a/sc/source/ui/vba/vbarange.cxx +++ b/sc/source/ui/vba/vbarange.cxx @@ -2361,7 +2361,7 @@ ScVbaRange::Rows(const uno::Any& aIndex ) { ScAddress::Details dDetails( formula::FormulaGrammar::CONV_XL_A1, 0, 0 ); ScRange tmpRange; - tmpRange.ParseRows( &getScDocument(), sAddress, dDetails ); + tmpRange.ParseRows( getScDocument(), sAddress, dDetails ); SCROW nStartRow = tmpRange.aStart.Row(); SCROW nEndRow = tmpRange.aEnd.Row(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits