diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-06-14 12:56:41 +0100 |
---|---|---|
committer | Michael Stahl <michael.stahl@allotropia.de> | 2022-09-22 21:54:37 +0200 |
commit | 268d8cd47312df921ed05385a25966a75165cede (patch) | |
tree | 63f6ba85ec10dacd1b6fa057943ef8f306a095b7 /sc | |
parent | bfedcc7c0b72819937ac0fb8a62852b4ec5f9f72 (diff) |
crashtesting: assert seen on loading forum-en-38962.ods
mismatched Push/Pop, catch offending exception
Change-Id: Ib2297a8ab04a2f2491e4c922d9e4db82a66ea911
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135841
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
(cherry picked from commit adc0d38ea1b434e0f5c996acce87fc9106706801)
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/data/dpobject.cxx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx index 73762cc70c54..33f923d4a26e 100644 --- a/sc/source/core/data/dpobject.cxx +++ b/sc/source/core/data/dpobject.cxx @@ -1022,7 +1022,16 @@ bool ScDPObject::GetMembers( sal_Int32 nDim, sal_Int32 nHier, vector<ScDPLabelDa for (sal_Int32 i = 0; i < nCount; ++i) { - Reference<container::XNamed> xMember(xMembersIA->getByIndex(i), UNO_QUERY); + Reference<container::XNamed> xMember; + try + { + xMember = Reference<container::XNamed>(xMembersIA->getByIndex(i), UNO_QUERY); + } + catch (const container::NoSuchElementException&) + { + TOOLS_WARN_EXCEPTION("sc", "ScNameToIndexAccess getByIndex failed"); + } + ScDPLabelData::Member aMem; if (xMember.is()) |