diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-01-30 21:15:31 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-01-30 21:15:31 +0000 |
commit | 76e372ccd999f42ad75c20d7eb8e359b608956fc (patch) | |
tree | 8783a1f78427a7dc39a53943d753f95eedf3ccb1 /forms | |
parent | 6ce0ca734f31489019605d3550cbe29a70d8e6f4 (diff) |
coverity#704645 Dereference after null check
Change-Id: Id6930c8e87f27051520e10e1277d769d0b380374
Diffstat (limited to 'forms')
-rw-r--r-- | forms/source/solar/component/navbarcontrol.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/forms/source/solar/component/navbarcontrol.cxx b/forms/source/solar/component/navbarcontrol.cxx index 8e6b4d4ce7d8..16aa480a2f31 100644 --- a/forms/source/solar/component/navbarcontrol.cxx +++ b/forms/source/solar/component/navbarcontrol.cxx @@ -140,10 +140,9 @@ namespace frm // create the peer ONavigationBarPeer* pPeer = ONavigationBarPeer::Create( m_xContext, pParentWin, getModel() ); - DBG_ASSERT( pPeer, "ONavigationBarControl::createPeer: invalid peer returned!" ); - if ( pPeer ) - // by definition, the returned component is acquired once - pPeer->release(); + assert(pPeer && "ONavigationBarControl::createPeer: invalid peer returned!"); + // by definition, the returned component is acquired once + pPeer->release(); // announce the peer to the base class setPeer( pPeer ); |