Kaydet (Commit) 54ceedfb authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1233491 Dereference null return value

Change-Id: Ia02749585cb9694bddb21e4f040cf6e025046be1
üst 9432b8d4
...@@ -1959,8 +1959,8 @@ namespace { ...@@ -1959,8 +1959,8 @@ namespace {
void testSheetProtection_Impl(ScDocument& rDoc) void testSheetProtection_Impl(ScDocument& rDoc)
{ {
CPPUNIT_ASSERT(rDoc.IsTabProtected(0)); CPPUNIT_ASSERT(rDoc.IsTabProtected(0));
ScTableProtection* pTabProtection = rDoc.GetTabProtection(0); ScTableProtection* pTabProtection = rDoc.GetTabProtection(0);
CPPUNIT_ASSERT(pTabProtection);
CPPUNIT_ASSERT(pTabProtection->isOptionEnabled(ScTableProtection::SELECT_UNLOCKED_CELLS)); CPPUNIT_ASSERT(pTabProtection->isOptionEnabled(ScTableProtection::SELECT_UNLOCKED_CELLS));
CPPUNIT_ASSERT(!pTabProtection->isOptionEnabled(ScTableProtection::SELECT_LOCKED_CELLS)); CPPUNIT_ASSERT(!pTabProtection->isOptionEnabled(ScTableProtection::SELECT_LOCKED_CELLS));
} }
......
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