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

coverity#1399032 Dereference null return value

Change-Id: I1482b1ce9a9ec9556e076c8f74185a9ce29e8d08
üst 1939a79c
...@@ -135,7 +135,9 @@ void PoolItemTest::testItemSet() ...@@ -135,7 +135,9 @@ void PoolItemTest::testItemSet()
CPPUNIT_ASSERT_EQUAL((sal_uInt16)1, aIter.GetFirstWhich()); CPPUNIT_ASSERT_EQUAL((sal_uInt16)1, aIter.GetFirstWhich());
CPPUNIT_ASSERT_EQUAL((sal_uInt16)7, aIter.GetLastWhich()); CPPUNIT_ASSERT_EQUAL((sal_uInt16)7, aIter.GetLastWhich());
CPPUNIT_ASSERT_EQUAL((sal_uInt16)1, aIter.FirstItem()->Which()); const SfxPoolItem *pFirstItem = aIter.FirstItem();
CPPUNIT_ASSERT(pFirstItem);
CPPUNIT_ASSERT_EQUAL((sal_uInt16)1, pFirstItem->Which());
CPPUNIT_ASSERT_EQUAL((sal_uInt16)2, aIter.NextItem()->Which()); CPPUNIT_ASSERT_EQUAL((sal_uInt16)2, aIter.NextItem()->Which());
CPPUNIT_ASSERT_EQUAL((sal_uInt16)3, aIter.NextItem()->Which()); CPPUNIT_ASSERT_EQUAL((sal_uInt16)3, aIter.NextItem()->Which());
CPPUNIT_ASSERT_EQUAL((sal_uInt16)5, aIter.NextItem()->Which()); CPPUNIT_ASSERT_EQUAL((sal_uInt16)5, aIter.NextItem()->Which());
......
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