[Libreoffice-bugs] [Bug 141511] CRASH: creating new document while navigator is displayed
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Tue Apr 6 11:36:25 UTC 2021
https://bugs.documentfoundation.org/show_bug.cgi?id=141511
Julien Nabet <serval2412 at yahoo.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |serval2412 at yahoo.fr
Keywords| |haveBacktrace
--- Comment #2 from Julien Nabet <serval2412 at yahoo.fr> ---
On pc Debian x86-64 with master sources updated today, I could reproduce this.
Here's part of bt:
#0 sd::DrawViewShell::GetEditMode() const (this=0x0) at
sd/source/ui/inc/DrawViewShell.hxx:237
#1 0x00007ff69472f9c3 in SdNavigatorControllerItem::StateChanged(unsigned
short, SfxItemState, SfxPoolItem const*) (this=0x8374d20, nSId=27288,
eState=SfxItemState::DEFAULT, pItem=0x83da790)
at sd/source/ui/dlg/navigatr.cxx:642
#2 0x00007ff6accafea0 in SfxStateCache::SetState_Impl(SfxItemState,
SfxPoolItem const*, bool) (this=0x8345a00, eState=SfxItemState::DEFAULT,
pState=0x83da790, bMaybeDirty=false)
at sfx2/source/control/statcach.cxx:423
#3 0x00007ff6accafbd1 in SfxStateCache::SetState(SfxItemState, SfxPoolItem
const*, bool) (this=0x8345a00, eState=SfxItemState::DEFAULT, pState=0x83da790,
bMaybeDirty=false)
at sfx2/source/control/statcach.cxx:324
#4 0x00007ff6acc1aaaa in
SfxBindings::UpdateControllers_Impl(SfxFoundCache_Impl const&, SfxPoolItem
const*, SfxItemState) (rFound=..., pItem=0x83da790, eState=SfxItemState::SET)
at sfx2/source/control/bindings.cxx:1218
=> naive patch:
diff --git a/sd/source/ui/dlg/navigatr.cxx b/sd/source/ui/dlg/navigatr.cxx
index c0e2ec79992e..b09edffc46b2 100644
--- a/sd/source/ui/dlg/navigatr.cxx
+++ b/sd/source/ui/dlg/navigatr.cxx
@@ -639,7 +639,7 @@ void SdNavigatorControllerItem::StateChanged( sal_uInt16
nSId,
{
const auto pDrawViewShell =
static_cast<::sd::DrawViewShell
*>(pDrawDocShell->GetViewShell());
- bool bEditModePage(pDrawViewShell->GetEditMode() == EditMode::Page);
+ bool bEditModePage(pDrawViewShell && (pDrawViewShell->GetEditMode() ==
EditMode::Page));
pNavigatorWin->mxToolbox->set_sensitive(bEditModePage);
pNavigatorWin->mxLbDocs->set_sensitive(bEditModePage);
pNavigatorWin->mxTlbObjects->set_sensitive(bEditModePage);
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20210406/c9a66233/attachment.htm>
More information about the Libreoffice-bugs
mailing list