summaryrefslogtreecommitdiffstats
path: root/sc/source/ui/docshell/tablink.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/docshell/tablink.cxx')
-rw-r--r--sc/source/ui/docshell/tablink.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sc/source/ui/docshell/tablink.cxx b/sc/source/ui/docshell/tablink.cxx
index 697b39052b9f..5414e19c1ca4 100644
--- a/sc/source/ui/docshell/tablink.cxx
+++ b/sc/source/ui/docshell/tablink.cxx
@@ -219,8 +219,9 @@ BOOL ScTableLink::Refresh(const String& rNewFile, const String& rNewFilter,
if ( bInEdit ) // only if using the edit dialog,
pMed->UseInteractionHandler( TRUE ); // enable the filter options dialog
+ // aRef->DoClose() will be called explicitly, but it is still more safe to use SfxObjectShellLock here
ScDocShell* pSrcShell = new ScDocShell(SFX_CREATE_MODE_INTERNAL);
- SfxObjectShellRef aRef = pSrcShell;
+ SfxObjectShellLock aRef = pSrcShell;
pSrcShell->DoLoad(pMed);
// Optionen koennten gesetzt worden sein