summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-12-19 04:36:55 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-12-28 12:54:16 +0100
commit643809553d63f87a02e1da822d1fb58c4f131ff2 (patch)
treee03263586b34fd89535de90792f24f19ce7ddf8f
parentefba557c24db07557a29b86ffb3188a20c0dc6f3 (diff)
fix invalid string access in OUString::copy
Change-Id: Idccec35f2838b54a7915aa4a0aeb229c69bae74d
-rw-r--r--sc/source/core/tool/rangeutl.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/tool/rangeutl.cxx b/sc/source/core/tool/rangeutl.cxx
index 9e2ce6b947ba..10fdf137765a 100644
--- a/sc/source/core/tool/rangeutl.cxx
+++ b/sc/source/core/tool/rangeutl.cxx
@@ -396,7 +396,7 @@ void ScRangeStringConverter::GetTokenByOffset(
sal_Unicode cQuote)
{
sal_Int32 nLength = rString.getLength();
- if( nOffset >= nLength )
+ if( nOffset == -1 || nOffset >= nLength )
{
rToken = OUString();
nOffset = -1;