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

coverity#736157 Dereference null return value

Change-Id: Ibc6e17e4d916ae9e1664e8c9149a978072dae0ac
üst f1fe85ec
...@@ -60,12 +60,12 @@ void SAL_CALL VCLXTabPageContainer::draw( sal_Int32 nX, sal_Int32 nY ) throw(Run ...@@ -60,12 +60,12 @@ void SAL_CALL VCLXTabPageContainer::draw( sal_Int32 nX, sal_Int32 nY ) throw(Run
if ( pTabControl ) if ( pTabControl )
{ {
TabPage *pTabPage = pTabControl->GetTabPage( sal::static_int_cast< sal_uInt16 >( pTabControl->GetCurPageId( ) ) ); TabPage *pTabPage = pTabControl->GetTabPage( sal::static_int_cast< sal_uInt16 >( pTabControl->GetCurPageId( ) ) );
if ( pTabPage ) OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( getGraphics() );
if (pTabPage && pDev)
{ {
::Point aPos( nX, nY ); ::Point aPos( nX, nY );
::Size aSize = pTabPage->GetSizePixel(); ::Size aSize = pTabPage->GetSizePixel();
OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( getGraphics() );
aPos = pDev->PixelToLogic( aPos ); aPos = pDev->PixelToLogic( aPos );
aSize = pDev->PixelToLogic( aSize ); aSize = pDev->PixelToLogic( aSize );
......
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