summaryrefslogtreecommitdiff
path: root/sc/source/ui/docshell/arealink.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/docshell/arealink.cxx')
-rw-r--r--sc/source/ui/docshell/arealink.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/ui/docshell/arealink.cxx b/sc/source/ui/docshell/arealink.cxx
index d819785c843b..1cd4c4700894 100644
--- a/sc/source/ui/docshell/arealink.cxx
+++ b/sc/source/ui/docshell/arealink.cxx
@@ -270,9 +270,9 @@ BOOL ScAreaLink::Refresh( const String& rNewFile, const String& rNewFilter,
SfxMedium* pMed = new SfxMedium(aNewUrl, STREAM_STD_READ, FALSE, pFilter);
+ // aRef->DoClose() will be closed explicitly, but it is still more safe to use SfxObjectShellLock here
ScDocShell* pSrcShell = new ScDocShell(SFX_CREATE_MODE_INTERNAL);
-//REMOVE SvEmbeddedObjectRef aRef = pSrcShell;
- SfxObjectShellRef aRef = pSrcShell;
+ SfxObjectShellLock aRef = pSrcShell;
pSrcShell->DoLoad(pMed);
ScDocument* pSrcDoc = pSrcShell->GetDocument();