diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-27 15:31:40 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-27 18:00:01 +0200 |
commit | db7e454bf7809b57c34c90e8876a3970a004ef16 (patch) | |
tree | b7bbf6da9600f4ffaa86823df9d92cbc38d1b200 /basic | |
parent | tdf#88205: Adapt uses of css::uno::Sequence to use initializer_list ctor (diff) | |
download | core-db7e454bf7809b57c34c90e8876a3970a004ef16.tar.gz core-db7e454bf7809b57c34c90e8876a3970a004ef16.zip |
tdf#120703 PVS: V668
V668 There is no sense in testing the 'pProc' pointer against null, as the
memory was allocated using the 'new' operator. The exception will be
generated in the case of memory allocation error.
Change-Id: Iec65fd44fa947a2402da33510c29730a46c2e1a4
Reviewed-on: https://gerrit.libreoffice.org/62424
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'basic')
-rw-r--r-- | basic/source/comp/dim.cxx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/basic/source/comp/dim.cxx b/basic/source/comp/dim.cxx index 5a3c27dd0577..3a984ce8c824 100644 --- a/basic/source/comp/dim.cxx +++ b/basic/source/comp/dim.cxx @@ -1215,17 +1215,13 @@ void SbiParser::DefProc( bool bStatic, bool bPrivate ) } pDef->Match( std::unique_ptr<SbiProcDef>(pProc) ); - pProc = pDef; } else { aPublics.Add( pDef ); - pProc = pDef; - } - if( !pProc ) - { - return; } + assert(pDef); + pProc = pDef; pProc->SetPublic( !bPrivate ); // Now we set the search hierarchy for symbols as well as the |