sc/source/core/tool/token.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a99f7ba5491051d9846bcd08834e997989fc1686
Author:     Mike Kaganski <mike.kagan...@collabora.com>
AuthorDate: Mon Aug 12 16:02:27 2024 +0500
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Tue Aug 20 10:41:16 2024 +0200

    Another case of pointers comparison
    
    Similar to https://gerrit.libreoffice.org/c/core/+/171756, this was
    this way since commit 7333881bb7b04f7e4e2a28638024ae82a9c14e81 (Formula
    tokens, formula cells and formula interpreters to use shared strings,
    2013-10-11). I don't know if this causes actual problems, but looks
    suspicious, and string comparison compares pointers for optimization.
    
    Change-Id: I544846b8b839606bdf2f118b87e5ea0c5961852f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171757
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>
    Tested-by: Jenkins
    Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com>
    (cherry picked from commit a9577dd52d4bcf273bae4abbc8f168eab777172d)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172001
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index 25c5b6f05f79..7a5eb545f78c 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -857,7 +857,7 @@ bool ScExternalNameToken::operator==( const FormulaToken& r 
) const
     if (mnFileId != r.GetIndex())
         return false;
 
-    return maName.getData() == r.GetString().getData();
+    return maName == r.GetString();
 }
 
 ScTableRefToken::ScTableRefToken( sal_uInt16 nIndex, ScTableRefToken::Item 
eItem ) :

Reply via email to