From c69ce3a0c32374c2f328583be2c81674a208256a Mon Sep 17 00:00:00 2001 From: Xisco Fauli Date: Wed, 23 Oct 2024 16:03:05 +0200 Subject: [PATCH] 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 Tested-by: Jenkins --- dbaccess/source/ui/querydesign/QueryTableView.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dbaccess/source/ui/querydesign/QueryTableView.cxx b/dbaccess/source/ui/querydesign/QueryTableView.cxx index f48dc17c7a3a..2ca8c71b837f 100644 --- a/dbaccess/source/ui/querydesign/QueryTableView.cxx +++ b/dbaccess/source/ui/querydesign/QueryTableView.cxx @@ -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;