tdf#163486: PVS: check pTabWinTmp

V595 	The 'pTabWinTmp' pointer was utilized before it was verified against nullptr. Check lines: 496, 499.

Change-Id: Ie263524d6a06adaf7f99555d7aa872e815cab96c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175504
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
This commit is contained in:
Xisco Fauli 2024-10-23 16:03:05 +02:00
parent f04ab0ea41
commit c69ce3a0c3

View file

@ -493,10 +493,10 @@ void OQueryTableView::AddTabWin(const OUString& _rComposedName, const OUString&
if ( pTabWinTmp == pNewTabWin )
continue;
assert(pTabWinTmp && "TableWindow is null!");
if ( pTabWinTmp->GetData()->isQuery() )
continue;
assert(pTabWinTmp && "TableWindow is null!");
Reference< XPropertySet > xFKKey = getKeyReferencedTo( pTabWinTmp->GetData()->getKeys(), pNewTabWin->GetComposedName() );
if ( !xFKKey.is() )
continue;