summaryrefslogtreecommitdiff
path: root/sc/source/core/tool/address.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/core/tool/address.cxx')
-rw-r--r--sc/source/core/tool/address.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
index 259018e213ce..4cf317073b56 100644
--- a/sc/source/core/tool/address.cxx
+++ b/sc/source/core/tool/address.cxx
@@ -365,7 +365,10 @@ const sal_Unicode* ScRange::Parse_XL_Header(
{
p = lcl_ParseQuotedName(p, rExternDocName);
if (!*p || *p != ']' || !rExternDocName.Len())
+ {
+ rExternDocName.Erase();
return start;
+ }
}
else
{
@@ -418,7 +421,10 @@ const sal_Unicode* ScRange::Parse_XL_Header(
// Excel does not allow [ and ] characters in sheet names though.
p = lcl_ParseQuotedName(p, rExternDocName);
if (!*p || *p != '!')
+ {
+ rExternDocName.Erase();
return start;
+ }
if (rExternDocName.Len())
{
xub_StrLen nOpen = rExternDocName.Search( '[');