[Libreoffice-commits] core.git: svl/source
Justin Luth
justin.luth at collabora.com
Wed May 16 05:25:04 UTC 2018
svl/source/items/itemprop.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 5dcb065d24fd9b57b6dc65a19a8a8c8bbaa22c44
Author: Justin Luth <justin.luth at collabora.com>
Date: Tue May 15 10:15:01 2018 +0300
NFC: unassigned variable pNewItem is always nullptr
In 2015 commit 2ebd79b3d214c62c0997606115ebc50700d6a760 a
possible initialization of the variable was removed. So
at this point pNewItem must return false.
Change-Id: I5af9d8440463c96323c38a01f255c1dbb0113e09
Reviewed-on: https://gerrit.libreoffice.org/54395
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Justin Luth <justin_luth at sil.org>
diff --git a/svl/source/items/itemprop.cxx b/svl/source/items/itemprop.cxx
index fd22a4f68733..98c19b200d90 100644
--- a/svl/source/items/itemprop.cxx
+++ b/svl/source/items/itemprop.cxx
@@ -218,7 +218,7 @@ void SfxItemPropertySet::setPropertyValue( const SfxItemPropertySimpleEntry& rEn
SfxItemState eState = rSet.GetItemState( rEntry.nWID, true, &pItem );
if (SfxItemState::SET != eState && SfxItemPool::IsWhich(rEntry.nWID))
pItem = &rSet.GetPool()->GetDefaultItem(rEntry.nWID);
- if(!pNewItem && pItem)
+ if (pItem)
{
pNewItem.reset(pItem->Clone());
}
More information about the Libreoffice-commits
mailing list