coverity#440982 Dereference after null check

Change-Id: I5e19801311c2cb038b6e1c5e7e52a6022f62ea86
This commit is contained in:
Caolán McNamara
2014-02-12 12:45:25 +00:00
parent 7141cfa6a3
commit cc7b1ee2f3

View File

@@ -1368,11 +1368,13 @@ void SfxDispatcher::Update_Impl( sal_Bool bForce )
// keep own tools internally for collecting
GetBindings()->GetDispatcher()->pImp->bUpdated = sal_False;
com::sun::star::uno::Reference< com::sun::star::frame::XFrame > xFrame;
SfxBindings* pBindings = GetBindings();
if ( pBindings )
if (pBindings)
{
pBindings->DENTERREGISTRATIONS();
com::sun::star::uno::Reference< com::sun::star::frame::XFrame > xFrame = pBindings->GetActiveFrame();
xFrame = pBindings->GetActiveFrame();
}
com::sun::star::uno::Reference< com::sun::star::beans::XPropertySet > xPropSet( xFrame, com::sun::star::uno::UNO_QUERY );
com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManager > xLayoutManager;
if ( xPropSet.is() )