Kaydet (Commit) ccf0f7ef authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#704633 Dereference after null check

Change-Id: I4985249110da93ba67881dcd1c8cd1dc66ae08e2
üst 2f52414e
...@@ -1196,11 +1196,12 @@ namespace pcr ...@@ -1196,11 +1196,12 @@ namespace pcr
// So, we manually switch this to read-only. // So, we manually switch this to read-only.
if ( xControl.is() && ( xControl->getControlType() == PropertyControlType::Unknown ) ) if ( xControl.is() && ( xControl->getControlType() == PropertyControlType::Unknown ) )
{ {
Edit* pControlWindowAsEdit = dynamic_cast< Edit* >( rLine.pLine->getControlWindow() ); Window *pWindow = rLine.pLine->getControlWindow();
if ( pControlWindowAsEdit ) Edit* pControlWindowAsEdit = dynamic_cast<Edit*>(pWindow);
pControlWindowAsEdit->SetReadOnly( sal_True ); if (pControlWindowAsEdit)
pControlWindowAsEdit->SetReadOnly(sal_True);
else else
pControlWindowAsEdit->Enable( false ); pWindow->Enable(false);
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment