summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sc/source/core/tool/address.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
index f704290e340d..7bd66f6402e4 100644
--- a/sc/source/core/tool/address.cxx
+++ b/sc/source/core/tool/address.cxx
@@ -2094,7 +2094,7 @@ static void lcl_Split_DocTab( const ScDocument& rDoc, SCTAB nTab,
rDoc.GetName(nTab, rTabName);
rDocName.clear();
// External reference, same as in ScCompiler::MakeTabStr()
- if ( rTabName[0] == '\'' )
+ if (!rTabName.isEmpty() && rTabName[0] == '\'')
{ // "'Doc'#Tab"
sal_Int32 nPos = ScCompiler::GetDocTabPos( rTabName);
if (nPos != -1)