diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-05-07 16:27:21 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-05-08 09:56:21 +0100 |
commit | 43d684af310266d454bd888da4f94df2c7714fc1 (patch) | |
tree | 64c91a8ff130c6531bbc1068e6b28b97f3f63d80 | |
parent | 7209f84fd3cfd10c85d334fb93f6b57e7547c99e (diff) |
coverity#736141 Dereference null return value
Change-Id: I1b4aadd64a8695142685ca49378e3c45ef2db28d
-rw-r--r-- | extensions/source/bibliography/bibload.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/extensions/source/bibliography/bibload.cxx b/extensions/source/bibliography/bibload.cxx index f6876cb29368..90ba39fe7a09 100644 --- a/extensions/source/bibliography/bibload.cxx +++ b/extensions/source/bibliography/bibload.cxx @@ -270,6 +270,7 @@ void BibliographyLoader::loadView(const Reference< XFrame > & rFrame, const OUSt Reference< awt::XWindow > aWindow = rFrame->getContainerWindow(); VCLXWindow* pParentComponent = VCLXWindow::GetImplementation(aWindow); + assert(pParentComponent); Window* pParent = VCLUnoHelper::GetWindow( aWindow ); @@ -293,10 +294,12 @@ void BibliographyLoader::loadView(const Reference< XFrame > & rFrame, const OUSt xCtrRef->attachFrame(rFrame); rFrame->setComponent( xWin, xCtrRef); pBeamer->SetXController(xCtrRef); - //! - // not earlier because SetFocus() is triggered in setVisible() - pParentComponent->setVisible(sal_True); + if (pParentComponent) + { + // not earlier because SetFocus() is triggered in setVisible() + pParentComponent->setVisible(sal_True); + } m_xDatMan->load(); // #100312# ---------- |