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

Hack to make an in-destruction SwFlyFrm no longer claim to be one

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

SwFrm::FindPageFrm()
SwAnchoredObject::FindPageFrmOfAnchor()
lcl_NotifyBackgroundOfObj(SwDrawContact&, SdrObject const&, Rectangle const*)
SwDrawContact::DisconnectFromLayout(bool)
SwDrawContact::DisconnectObjFromLayout(SdrObject*)
SwLayoutFrm::Destroy()
SwLayoutFrm::~SwLayoutFrm()
SwFlyFrm::~SwFlyFrm()
SwFlyFreeFrm::~SwFlyFreeFrm()
SwFlyLayFrm::~SwFlyLayFrm()
SwLayoutFrm::Destroy()
SwRootFrm::~SwRootFrm()
...
boost::shared_ptr<SwRootFrm>::~shared_ptr()
SwViewShell::~SwViewShell()
SwCrsrShell::~SwCrsrShell()
SwEditShell::~SwEditShell()
SwFEShell::~SwFEShell()
SwWrtShell::~SwWrtShell()
SwView::~SwView()
SfxViewFrame::ReleaseObjectShell_Impl()
SfxViewFrame::~SfxViewFrame()
SfxViewFrame::Close()
...

Change-Id: I56d7135044e8682eeaf6ef23c76d4d7beca1eff4
üst a015f2c1
...@@ -268,6 +268,10 @@ SwFlyFrm::~SwFlyFrm() ...@@ -268,6 +268,10 @@ SwFlyFrm::~SwFlyFrm()
} }
FinitDrawObj(); FinitDrawObj();
// Hack to make sure code called from base ~SwLayoutFrm does not interpret
// this as a SwFlyFrm (which it no longer is by then):
mnFrmType = FRM_UNUSED;
} }
const IDocumentDrawModelAccess* SwFlyFrm::getIDocumentDrawModelAccess() const IDocumentDrawModelAccess* SwFlyFrm::getIDocumentDrawModelAccess()
......
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