summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-05-28 22:33:29 -0400
committerKohei Yoshida <kohei.yoshida@collabora.com>2014-05-29 22:00:48 -0400
commit9832a2482f157d34f7323327dc20eaf5e11da3fd (patch)
tree6e03b6b7eb4f6144184007486aa6797802cb04db /desktop
parentad9e67a7c08f9ceb3b4c228e3d9241c4ed54a7c8 (diff)
Detach all DocBasicItem objects upon process termination.
To prevent rogue DocBasicItem objects (which are global objects) from attempting to stop listening after the main app is dead. Change-Id: I68a667137ca4e0eff18278f4d2d5dd67466eaf34 (cherry picked from commit a916b6ff7fdf1bcb1182e72e4a5bf2f901c698da)
Diffstat (limited to 'desktop')
-rw-r--r--desktop/Library_sofficeapp.mk1
-rw-r--r--desktop/source/app/app.cxx2
2 files changed, 3 insertions, 0 deletions
diff --git a/desktop/Library_sofficeapp.mk b/desktop/Library_sofficeapp.mk
index 0c6c3e71f0ba..01950fcc5b0a 100644
--- a/desktop/Library_sofficeapp.mk
+++ b/desktop/Library_sofficeapp.mk
@@ -39,6 +39,7 @@ $(eval $(call gb_Library_use_libraries,sofficeapp,\
i18nlangtag \
sal \
salhelper \
+ sb \
sfx \
svl \
svt \
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index bb14e03470a2..9fa787cd8d85 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -98,6 +98,7 @@
#include <sfx2/app.hxx>
#include <svl/itemset.hxx>
#include <svl/eitem.hxx>
+#include <basic/sbstar.hxx>
#include <svtools/fontsubstconfig.hxx>
#include <svtools/accessibilityoptions.hxx>
@@ -1766,6 +1767,7 @@ int Desktop::doShutdown()
// with the solar mutex unlocked, to avoid deadlock:
sal_uLong nAcquireCount = Application::ReleaseSolarMutex();
DeregisterServices();
+ StarBASIC::DetachAllDocBasicItems();
Application::AcquireSolarMutex(nAcquireCount);
// be sure that path/language options gets destroyed before
// UCB is deinitialized