summaryrefslogtreecommitdiff
path: root/include/com
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2022-01-07 10:01:46 +0100
committerMichael Weghorn <m.weghorn@posteo.de>2022-01-25 16:31:17 +0100
commitad19d0c354887ac05561ca009a3f89cc62dfe9cf (patch)
tree9c4eb767d879ff0a4c15de813ec3c9a145d24d8e /include/com
parent5cc40c5b89c8d651e9d38d2b6d388399c3fe8664 (diff)
uno sequences with different sizes are not equal
This should often the case, and should be way faster than the UNO data comparison. Change-Id: Ied648d75779ef3aafd293c36906a1bab66bdeade Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128098 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com> (cherry picked from commit 9e7e63b8f812977b253b05db8a02dd0444de375a) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128816 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'include/com')
-rw-r--r--include/com/sun/star/uno/Sequence.hxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/com/sun/star/uno/Sequence.hxx b/include/com/sun/star/uno/Sequence.hxx
index 7aa873e91223..23b12099791f 100644
--- a/include/com/sun/star/uno/Sequence.hxx
+++ b/include/com/sun/star/uno/Sequence.hxx
@@ -139,6 +139,8 @@ inline bool Sequence< E >::operator == ( const Sequence & rSeq ) const
{
if (_pSequence == rSeq._pSequence)
return true;
+ if (_pSequence->nElements != rSeq._pSequence->nElements)
+ return false;
const Type & rType = ::cppu::getTypeFavourUnsigned( this );
return ::uno_type_equalData(
const_cast< Sequence * >( this ), rType.getTypeLibType(),