diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-04-13 18:01:46 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-04-13 18:01:46 +0200 |
commit | 7f863e890640d0924a6e6f85cf99447dcd7836f7 (patch) | |
tree | ac69c678af56d8b86a78d91cf536c9ac8db41769 /vcl/source/window/toolbox2.cxx | |
parent | 470f16acc2a798f0ae1ebe9ce2080084ab167e80 (diff) |
Avoid null ToolBox::mpData deref during Frame::close
Oh my, whatever the true cause for this SEGV in JunitTest_framework_complex,
<http://ci.libreoffice.org/job/lo_tb_master_linux_dbg/6628/console>, processing
an incoming URP request
> ToolBox::GetMenu() const at vcl/source/window/toolbox2.cxx:1775
> framework::ToolBarManager::ImplClearPopupMenu(ToolBox*) at framework/source/uielement/toolbarmanager.cxx:1309
> framework::ToolBarManager::dispose() at framework/source/uielement/toolbarmanager.cxx:470
> framework::ToolBarWrapper::dispose() at framework/source/uielement/toolbarwrapper.cxx:106
> framework::ToolbarLayoutManager::destroyToolbars() at framework/source/layoutmanager/toolbarlayoutmanager.cxx:654
> framework::ToolbarLayoutManager::reset() at framework/source/layoutmanager/toolbarlayoutmanager.cxx:363
> framework::LayoutManager::implts_reset(bool) at framework/source/layoutmanager/layoutmanager.cxx:413
> framework::LayoutManager::frameAction(com::sun::star::frame::FrameActionEvent const&) at framework/source/layoutmanager/layoutmanager.cxx:2804
> (anonymous namespace)::Frame::implts_sendFrameActionEvent(com::sun::star::frame::FrameAction const&) at framework/source/services/frame.cxx:2953
> (anonymous namespace)::Frame::setComponent(com::sun::star::uno::Reference<com::sun::star::awt::XWindow> const&, com::sun::star::uno::Reference<com::sun::star::frame::XController> const&) at framework/source/services/frame.cxx:1449
> (anonymous namespace)::Frame::close(sal_Bool) at framework/source/services/frame.cxx:1689
> framework::Desktop::impl_closeFrames(bool) at framework/source/services/desktop.cxx:1674
> framework::Desktop::terminate() at framework/source/services/desktop.cxx:238
and the main thread idling in Application::Yield.
Change-Id: I41ff8007ee4bbc37473aa5f077ff706b51d31c64
Diffstat (limited to 'vcl/source/window/toolbox2.cxx')
-rw-r--r-- | vcl/source/window/toolbox2.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx index ff1536115527..2d1294cc9939 100644 --- a/vcl/source/window/toolbox2.cxx +++ b/vcl/source/window/toolbox2.cxx @@ -1772,7 +1772,7 @@ bool ToolBox::IsMenuEnabled() const PopupMenu* ToolBox::GetMenu() const { - return mpData->mpMenu; + return mpData == nullptr ? nullptr : mpData->mpMenu; } void ToolBox::SetMenuButtonHdl( const Link<ToolBox *, void>& rLink ) |