summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2015-01-20 19:45:08 +0100
committerEike Rathke <erack@redhat.com>2015-01-20 19:47:47 +0100
commit8825e95a44395b5c4675f077e99fe4d9fb47c62f (patch)
treec5a9450bc60abac68fab081a4759e3811465bdc4
parent5c363cf3f1d75e37835a6663a96b4e22c754c4cb (diff)
change assert() to SAL_WARN_IF()
It's a valid condition in some cases. Change-Id: I9c9bbcf0b506a88f89e4a420dd544e4bc6502e58
-rw-r--r--sc/source/core/tool/compiler.cxx6
1 files changed, 5 insertions, 1 deletions
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index e53a50912c11..fee41593812c 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -4160,7 +4160,11 @@ void ScCompiler::CreateStringFromExternal(OUStringBuffer& rBuffer, FormulaToken*
{
vector<OUString> aTabNames;
pRefMgr->getAllCachedTableNames(nFileId, aTabNames);
- assert(!aTabNames.empty()); // something is seriously wrong, but continue
+ // No sheet names is a valid case if external sheets were not
+ // cached in this document and external document is not reachable,
+ // else not and worth to be investigated.
+ SAL_WARN_IF( aTabNames.empty(), "sc.core", "wrecked cache of external document? '" <<
+ *pFileName << "' '" << t->GetString().getString() << "'");
pConv->makeExternalRefStr(
rBuffer, GetPos(), nFileId, *pFileName, aTabNames, t->GetString().getString(),