diff options
author | Caolán McNamara <caolanm@redhat.com> | 2020-09-15 12:15:43 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2020-09-16 14:22:34 +0200 |
commit | b49dada831604bbc929323719106c2474ef1102a (patch) | |
tree | 793d4a4c90e46237dc4b17cfd3032dae364178d8 /sc/source/core | |
parent | b979802fc92c8386fa35893f3c620082cec8fbde (diff) |
IsNameValid never passed a null ScDocument*
Change-Id: I2bef21f5c6356823b3c0470e7640896740e2ee9c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102844
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc/source/core')
-rw-r--r-- | sc/source/core/tool/rangenam.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sc/source/core/tool/rangenam.cxx b/sc/source/core/tool/rangenam.cxx index a02191038db2..639b7734da92 100644 --- a/sc/source/core/tool/rangenam.cxx +++ b/sc/source/core/tool/rangenam.cxx @@ -464,7 +464,7 @@ void ScRangeData::MakeValidName( const ScDocument& rDoc, OUString& rName ) } } -ScRangeData::IsNameValidType ScRangeData::IsNameValid( const OUString& rName, const ScDocument* pDoc ) +ScRangeData::IsNameValidType ScRangeData::IsNameValid( const OUString& rName, const ScDocument& rDoc ) { /* XXX If changed, sc/source/filter/ftools/ftools.cxx * ScfTools::ConvertToScDefinedName needs to be changed too. */ @@ -487,8 +487,8 @@ ScRangeData::IsNameValidType ScRangeData::IsNameValid( const OUString& rName, co ScAddress::Details details( static_cast<FormulaGrammar::AddressConvention>( nConv ) ); // Don't check Parse on VALID, any partial only VALID may result in // #REF! during compile later! - if (aRange.Parse(rName, pDoc, details) != ScRefFlags::ZERO || - aAddr.Parse(rName, pDoc, details) != ScRefFlags::ZERO ) + if (aRange.Parse(rName, &rDoc, details) != ScRefFlags::ZERO || + aAddr.Parse(rName, &rDoc, details) != ScRefFlags::ZERO ) { return NAME_INVALID_CELL_REF; } |