Bugzilla – Attachment 49761 Details for
Bug 39510
CRASH closing document with footnotes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch for debugging the issue
debug_fdo39510.diff (text/plain), 2.39 KB, created by
Björn Michaelsen
on 2011-07-31 06:50:45 UTC
(
hide
)
Description:
patch for debugging the issue
Filename:
MIME Type:
Creator:
Björn Michaelsen
Created:
2011-07-31 06:50:45 UTC
Size:
2.39 KB
patch
obsolete
>diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx >index 111afa7..969e49f 100644 >--- a/sw/source/core/doc/docnew.cxx >+++ b/sw/source/core/doc/docnew.cxx >@@ -203,6 +203,20 @@ sal_Bool lcl_DelFmtIndizes( const SwFrmFmtPtr& rpFmt, void* ) > return sal_True; > } > >+#if OSL_DEBUG_LEVEL > 0 >+static SwDoc* pLastLoadedDoc = NULL; >+void debug_SetLastLoadedDoc(SwDoc* pDoc) >+{ >+ pLastLoadedDoc = pDoc; >+ OSL_TRACE("Last loaded doc is now: %p", pLastLoadedDoc); >+} >+SwDoc* debug_GetLastLoadedDoc() >+{ >+ OSL_TRACE("Last loaded doc is now: %p", pLastLoadedDoc); >+ return pLastLoadedDoc; >+} >+#endif >+ > /* > * exportierte Methoden > */ >@@ -431,6 +445,9 @@ SwDoc::SwDoc() > } > > ResetModified(); >+#if OSL_DEBUG_LEVEL > 0 >+ debug_SetLastLoadedDoc(this); >+#endif > } > > /* >diff --git a/sw/source/core/layout/ftnfrm.cxx b/sw/source/core/layout/ftnfrm.cxx >index a8e1b46..b80dce0 100644 >--- a/sw/source/core/layout/ftnfrm.cxx >+++ b/sw/source/core/layout/ftnfrm.cxx >@@ -3238,4 +3238,44 @@ SwCntntFrm* SwFtnFrm::FindLastCntnt() > return pLastCntntFrm; > } > >+#if OSL_DEBUG_LEVEL > 0 >+static void debug_checkCntntNodeFollow(const SwDoc* const pDoc) >+{ >+ const SwNodes* const pNodes = &pDoc->GetNodes(); >+ const SwRootFrm* const pRootFrm = pDoc->GetCurrentLayout(); >+ if(!pRootFrm) >+ { >+ OSL_FAIL("SwDoc has no RootFrame"); >+ return; >+ } >+ int nCount = pNodes->Count(); >+ for(int nCurrent = 0; nCurrent < nCount; ++nCurrent) >+ { >+ SwNode* pNode = (*pNodes)[nCurrent]; >+ if(pNode->IsCntntNode()) >+ { >+ SwCntntNode* pCntntNode = dynamic_cast<SwCntntNode*>(pNode); >+ if(pCntntNode) >+ { >+ SwCntntFrm* pCntntFrm = pCntntNode->getLayoutFrm( >+ pRootFrm, >+ 0, 0, false); >+ if(!pCntntFrm) >+ OSL_TRACE("pCntntNode %p has no CntntFrm", pCntntNode); >+ else >+ { >+ if(pCntntFrm->IsFollow()) >+ { >+ if(!pCntntFrm->FindMaster()) >+ OSL_TRACE("CntntFrm %p is lost in space", pCntntFrm); >+ } >+ } >+ } >+ else >+ OSL_FAIL("IsCntntNode()==true, but dynamic_cast<SwCntntNode*>(pNode)==NULL)"); >+ } >+ } >+} >+#endif >+ > /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 39510
:
49478
|
49536
|
49761
|
49762
|
49780
|
50269
|
51098
|
51163
|
51329
|
51524