Fix tdf#124708: CRASH: Selecting all and deleting

Change-Id: I0de912dad97f266a56ab52a351b0676f17675ed5
Reviewed-on: https://gerrit.libreoffice.org/82332
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
This commit is contained in:
Muhammet Kara
2019-11-09 00:14:11 +03:00
parent 1b66d0141c
commit 8023a613e9

View File

@@ -282,9 +282,13 @@ namespace sd
Reference< XAnimationNode > CustomAnimationClonerImpl::getClonedNode( const Reference< XAnimationNode >& xSource ) const
{
sal_Int32 nNode, nNodeCount = maSourceNodeVector.size();
std::size_t nNodeCount = maSourceNodeVector.size();
std::size_t nCloneNodeCount = maCloneNodeVector.size();
for( nNode = 0; nNode < nNodeCount; nNode++ )
if (nNodeCount != nCloneNodeCount)
SAL_WARN("sd.core", "Sizes of maSourceNodeVector and maCloneNodeVector mismatch!");
for( std::size_t nNode = 0; nNode < nNodeCount && nNode < nCloneNodeCount; ++nNode )
{
if( maSourceNodeVector[nNode] == xSource )
return maCloneNodeVector[nNode];