summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sc/source/core/tool/token.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index 727a3d6d1a4a..bcb7a7b802d9 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -2345,9 +2345,9 @@ void ScTokenArray::ReadjustAbsolute3DReferences( const ScDocument* pOldDoc, cons
OUString aTabName;
sal_uInt16 nFileId;
GetExternalTableData(pOldDoc, pNewDoc, rRef1.Tab(), aTabName, nFileId);
- pCode[j]->DecRef();
ScExternalDoubleRefToken* pToken = new ScExternalDoubleRefToken(nFileId, aTabName, rRef);
pToken->IncRef();
+ pCode[j]->DecRef(); // ATTENTION: rRef can't be used after this point
pCode[j] = pToken;
}
}