[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - basic/source

Julien Nabet serval2412 at yahoo.fr
Tue Feb 7 13:00:10 UTC 2017


 basic/source/comp/scanner.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 50522e609375ad12dec9c24cc302d9107cbf5358
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Sun Feb 5 14:01:59 2017 +0100

    Related tdf#105473: Crash in: ScRangeList::operator[]
    
    fixes this bt:
    3  0x00002aaaab314ef2 in __GI___assert_fail (assertion=assertion at entry=0x2aaaaf8dc448 "index >= 0 && static_cast<sal_uInt32>(index) < static_cast<sal_uInt32>(getLength())",
        file=file at entry=0x2aaaaf8ac488 "/home/julien/lo/libreoffice/include/rtl/ustring.hxx", line=line at entry=678,
        function=function at entry=0x2aaaaf8dc800 <rtl::OUString::operator[](int) const::__PRETTY_FUNCTION__> "sal_Unicode rtl::OUString::operator[](sal_Int32) const")
        at assert.c:101
    4  0x00002aaaaf810383 in rtl::OUString::operator[] (this=this at entry=0x55555d39c9f8, index=index at entry=0) at /home/julien/lo/libreoffice/include/rtl/ustring.hxx:678
    5  0x00002aaaaf822f4e in SbiScanner::NextSym (this=0x55555d39c9d0) at /home/julien/lo/libreoffice/basic/source/comp/scanner.cxx:572
    6  0x00002aaaaf82771e in SbiTokenizer::Next (this=this at entry=0x55555d39c9d0) at /home/julien/lo/libreoffice/basic/source/comp/token.cxx:339
    7  0x00002aaaaf827d23 in SbiTokenizer::Peek (this=0x55555d39c9d0) at /home/julien/lo/libreoffice/basic/source/comp/token.cxx:266
    8  0x00002aaaaf8175d0 in SbiExpression::Unary (this=this at entry=0x55555d43cea0) at /home/julien/lo/libreoffice/basic/source/comp/exprtree.cxx:581
    9  0x00002aaaaf8178a4 in SbiExpression::Exp (this=this at entry=0x55555d43cea0) at /home/julien/lo/libreoffice/basic/source/comp/exprtree.cxx:633
    10 0x00002aaaaf81792c in SbiExpression::MulDiv (this=this at entry=0x55555d43cea0) at /home/julien/lo/libreoffice/basic/source/comp/exprtree.cxx:647
    11 0x00002aaaaf8179b6 in SbiExpression::IntDiv (this=this at entry=0x55555d43cea0) at /home/julien/lo/libreoffice/basic/source/comp/exprtree.cxx:666
    
    Change-Id: Ib56063b3106bd077cda215e34ab763bae1f33c33
    Reviewed-on: https://gerrit.libreoffice.org/33933
    Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
    Tested-by: Julien Nabet <serval2412 at yahoo.fr>
    (cherry picked from commit 89b57084a0b76c20d6f98607c88b47009a1975d5)
    Reviewed-on: https://gerrit.libreoffice.org/33935
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/basic/source/comp/scanner.cxx b/basic/source/comp/scanner.cxx
index bb263a8..e3a622b 100644
--- a/basic/source/comp/scanner.cxx
+++ b/basic/source/comp/scanner.cxx
@@ -569,7 +569,7 @@ eoln:
     {
         pLine = nullptr;
         bool bRes = NextSym();
-        if( bVBASupportOn && aSym[0] == '.' )
+        if( bVBASupportOn && aSym.startsWith(".") )
         {
             // object _
             //    .Method


More information about the Libreoffice-commits mailing list