Kaydet (Commit) dedc93e9 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Hack to work around an in-destruction SwTxtNode no longer being one

as observed by -fsanitize=vptr e.g. during CppunitTest_sw_mailmerge (though the
true fix might be to prevent all this from happening during ~SwTxtNode anyway?):

SwTxtFrm::GetTxtNode() const
SwFrm::InvalidatePage(SwPageFrm const*) const
SwCntntFrm::Cut()
SwCntntNode::DelFrms(bool)
SwCntntNode::~SwCntntNode()
SwTxtNode::~SwTxtNode()
SwNodes::RemoveNode(unsigned long, unsigned long, bool)
SwNodes::Delete(SwNodeIndex const&, unsigned long)
SwDoc::AppendDoc(SwDoc const&, unsigned short, SwPageDesc*, bool, int)
...

Change-Id: Ic3bdf067abba985a0b95d4f0a482a94098341198
üst db2c0dc7
...@@ -435,13 +435,9 @@ void SwFrm::InvalidatePage( const SwPageFrm *pPage ) const ...@@ -435,13 +435,9 @@ void SwFrm::InvalidatePage( const SwPageFrm *pPage ) const
} }
pRoot->SetIdleFlags(); pRoot->SetIdleFlags();
const SwTxtFrm *pTxtFrm = dynamic_cast< const SwTxtFrm * >(this); const SwTxtNode *pTxtNode = dynamic_cast< const SwTxtNode * >(GetDep());
if (pTxtFrm) if (pTxtNode && pTxtNode->IsGrammarCheckDirty())
{ pRoot->SetNeedGrammarCheck( true );
const SwTxtNode *pTxtNode = pTxtFrm->GetTxtNode();
if (pTxtNode && pTxtNode->IsGrammarCheckDirty())
pRoot->SetNeedGrammarCheck( true );
}
} }
} }
......
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