From d4f7fc2a892f50873a1f7ded156c55c797adff34 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Thu, 23 Aug 2018 15:57:47 +0100 Subject: tdf#117426 don't crash is infobar is disposed in preview view MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Iff2dece2ea5f65c5d0896af888e05703ae709c65 Reviewed-on: https://gerrit.libreoffice.org/59512 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- sfx2/source/doc/objserv.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sfx2') diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx index 22e61ec98aad..1755be26b741 100644 --- a/sfx2/source/doc/objserv.cxx +++ b/sfx2/source/doc/objserv.cxx @@ -1079,7 +1079,7 @@ void SfxObjectShell::GetState_Impl(SfxItemSet &rSet) if ( !sMessage.isEmpty() ) { auto pInfoBar = pFrame->AppendInfoBar("signature", sMessage, aInfoBarType); - if (pInfoBar == nullptr) + if (pInfoBar == nullptr || pInfoBar->IsDisposed()) return; VclPtrInstance xBtn(&(pFrame->GetWindow())); xBtn->SetText(SfxResId(STR_SIGNATURE_SHOW)); -- cgit