Kaydet (Commit) bbdecd90 authored tarafından Eike Rathke's avatar Eike Rathke

coverity#735814 Explicit null dereferenced

Change-Id: I7c6ebe65cd8c3364b541b5545ab36a13d155a61c
üst d58c32fc
...@@ -237,8 +237,10 @@ void ScNameDefDlg::AddPushed() ...@@ -237,8 +237,10 @@ void ScNameDefDlg::AddPushed()
if (!mpDoc->GetTable(aScope, nTab)) if (!mpDoc->GetTable(aScope, nTab))
nTab = -1; nTab = -1;
mpDocShell->GetUndoManager()->AddUndoAction( assert( pNewEntry); // undo of no insertion smells fishy
new ScUndoAddRangeData( mpDocShell, pNewEntry, nTab) ); if (pNewEntry)
mpDocShell->GetUndoManager()->AddUndoAction(
new ScUndoAddRangeData( mpDocShell, pNewEntry, nTab) );
// set table stream invalid, otherwise RangeName won't be saved if no other // set table stream invalid, otherwise RangeName won't be saved if no other
// call invalidates the stream // call invalidates the stream
......
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