summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--basic/source/comp/scanner.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/basic/source/comp/scanner.cxx b/basic/source/comp/scanner.cxx
index 968458f696a8..bb263a802f12 100644
--- a/basic/source/comp/scanner.cxx
+++ b/basic/source/comp/scanner.cxx
@@ -421,7 +421,7 @@ bool SbiScanner::NextSym()
}
// Hex/octal number? Read in and convert:
- else if(nCol < aLine.getLength() && aLine[nCol] == '&')
+ else if(aLine.getLength() - nCol > 1 && aLine[nCol] == '&')
{
++pLine; ++nCol;
sal_Unicode base = 16;