Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


On 13/01/12 18:07, Cedric Bosdonnat wrote:
Hi all,

Could some of the other Writer gurus have a look at this patch: it
should fix the crasher though it may not be perfect. I'ld prefer a peer
review before cherry-picking it to 3.5

http://cgit.freedesktop.org/libreoffice/core/commit/?id=d83488

hmmm... i've looked at the problem quite a bit, and my current opinion
is that your fix maybe doesn't really address the root cause, but it
doesn't seem to cause any obvious problems either, so i've pushed it.

the problem is really that we call a listener that wants to paint the
document in the middle of a layout, while the layout is in an
inconsistent state; but i'm not sure what exactly could be done about that.

here we are deleting the page, because it is empty:

#0  SwPageFrm::~SwPageFrm (this=0x2754040, __in_chrg=<optimized out>) at 
/data/lo/core_3_5/sw/source/core/layout/pagechg.cxx:327
#1  0x00007fce48f2f338 in SwLayAction::RemoveEmptyBrowserPages (this=0x7fff460fb030) at 
/data/lo/core_3_5/sw/source/core/layout/layact.cxx:428
#2  0x00007fce48f2f4a7 in SwLayAction::Action (this=0x7fff460fb030) at 
/data/lo/core_3_5/sw/source/core/layout/layact.cxx:467
#3  0x00007fce48f6bf07 in SwRootFrm::Paint (this=0x291e1b0, rRect=..., pPrintData=0x0) at 
/data/lo/core_3_5/sw/source/core/layout/paintfrm.cxx:2824
#4  0x00007fce492f32c6 in ViewShell::PrtOle2 (pDoc=0x27e23b0, pOpt=0x1a2a2b0, rOptions=..., 
pOleOut=0x7fff460fb680, rRect=...) at /data/lo/core_3_5/sw/source/core/view/vprint.cxx:582
#5  0x00007fce494379b8 in SwDocShell::Draw (this=0x27dfbb0, pDev=0x7fff460fb680, rSetup=..., 
nAspect=1) at /data/lo/core_3_5/sw/source/ui/app/docsh.cxx:838
#6  0x00007fce6992bbfb in SfxObjectShell::DoDraw_Impl (this=0x27dfbb0, pDev=0x7fff460fb680, 
rViewPos=..., rScaleX=1/1, rScaleY=1/1, rSetup=..., nAspect=1) at 
/data/lo/core_3_5/sfx2/source/doc/objembed.cxx:248
#7  0x00007fce6992b7e2 in SfxObjectShell::DoDraw (this=0x27dfbb0, pDev=0x7fff460fb680, 
rObjPos=..., rSize=..., rSetup=..., nAspect=1) at 
/data/lo/core_3_5/sfx2/source/doc/objembed.cxx:195
#8  0x00007fce69926349 in SfxObjectShell::CreatePreviewMetaFile_Impl (this=0x27dfbb0, 
bFullContent=1 '\001') at /data/lo/core_3_5/sfx2/source/doc/objcont.cxx:174
#9  0x00007fce69925f9a in SfxObjectShell::GetPreviewMetaFile (this=0x27dfbb0, bFullContent=1 
'\001') at /data/lo/core_3_5/sfx2/source/doc/objcont.cxx:121
#10 0x00007fce6998d609 in SfxBaseModel::getTransferData (this=0x27e6820, aFlavor=...) at 
/data/lo/core_3_5/sfx2/source/doc/sfxbasemodel.cxx:2063
#11 0x00007fce69996076 in SfxBaseModel::getPreferredVisualRepresentation (this=0x27e6820) at 
/data/lo/core_3_5/sfx2/source/doc/sfxbasemodel.cxx:3498
#12 0x00007fce418efbee in OCommonEmbeddedObject::getPreferredVisualRepresentation(long) () from 
/data/lo/core_3_5/solver/unxlngx6/installation/opt/program/../program/libembobj.so
#13 0x00007fce6a89ddb5 in comphelper::EmbeddedObjectContainer::GetGraphicReplacementStream 
(nViewAspect=1, xObj=..., pMediaType=0x1a4a960) at 
/data/lo/core_3_5/comphelper/source/container/embeddedobjectcontainer.cxx:1574
#14 0x00007fce68b94120 in svt::EmbeddedObjectRef::GetGraphicReplacementStream (nViewAspect=1, 
xObj=..., pMediaType=0x1a4a960) at /data/lo/core_3_5/svtools/source/misc/embedhlp.cxx:747
#15 0x00007fce68b93195 in svt::EmbeddedObjectRef::GetGraphicStream (this=0x160f130, bUpdate=1 
'\001') at /data/lo/core_3_5/svtools/source/misc/embedhlp.cxx:581
#16 0x00007fce68b92654 in svt::EmbeddedObjectRef::GetReplacement (this=0x160f130, bUpdate=1 
'\001') at /data/lo/core_3_5/svtools/source/misc/embedhlp.cxx:421
#17 0x00007fce68b94901 in svt::EmbeddedObjectRef::UpdateReplacement (this=0x160f130) at 
/data/lo/core_3_5/solver/unxlngx6/inc/svtools/embedhlp.hxx:110
#18 0x00007fce68b917a3 in svt::EmbedEventListener_Impl::modified (this=0x270f390) at 
/data/lo/core_3_5/svtools/source/misc/embedhlp.cxx:179
#19 0x00007fce698b3e38 in 
cppu::OInterfaceContainerHelper::NotifySingleListener<com::sun::star::util::XModifyListener, 
com::sun::star::lang::EventObject>::operator() (this=0x7fff460fc240, listener=...) at 
/data/lo/core_3_5/solver/unxlngx6/inc/cppuhelper/interfacecontainer.h:271
#20 0x00007fce698af233 in 
cppu::OInterfaceContainerHelper::forEach<com::sun::star::util::XModifyListener, 
cppu::OInterfaceContainerHelper::NotifySingleListener<com::sun::star::util::XModifyListener, 
com::sun::star::lang::EventObject> > (this=0x2832ed0, func=...) at 
/data/lo/core_3_5/solver/unxlngx6/inc/cppuhelper/interfacecontainer.h:288
#21 0x00007fce698ab974 in 
cppu::OInterfaceContainerHelper::notifyEach<com::sun::star::util::XModifyListener, 
com::sun::star::lang::EventObject> (this=0x2832ed0, NotificationMethod=&virtual table offset 32, 
Event=...) at /data/lo/core_3_5/solver/unxlngx6/inc/cppuhelper/interfacecontainer.h:302
#22 0x00007fce69990f89 in SfxBaseModel::NotifyModifyListeners_Impl (this=0x27e6820) at 
/data/lo/core_3_5/sfx2/source/doc/sfxbasemodel.cxx:2630
#23 0x00007fce6999105f in SfxBaseModel::changing (this=0x27e6820) at 
/data/lo/core_3_5/sfx2/source/doc/sfxbasemodel.cxx:2646
#24 0x00007fce699904b8 in SfxBaseModel::Notify (this=0x27e6820, rBC=..., rHint=...) at 
/data/lo/core_3_5/sfx2/source/doc/sfxbasemodel.cxx:2528
#25 0x00007fce691dea8b in SfxBroadcaster::Broadcast (this=0x27dfbb0, rHint=...) at 
/data/lo/core_3_5/svl/source/notify/brdcst.cxx:64
#26 0x00007fce48f5e7cd in SwRootFrm::CheckViewLayout (this=0x291e1b0, pViewOpt=0x0, pVisArea=0x0) 
at /data/lo/core_3_5/sw/source/core/layout/pagechg.cxx:2397
#27 0x00007fce48f5a546 in SwPageFrm::Paste (this=0x2754040, pParent=0x291e1b0, pSibling=0x0) at 
/data/lo/core_3_5/sw/source/core/layout/pagechg.cxx:1006

here we are inserting the same page, newly created ^^^

#28 0x00007fce48f5b4bf in SwFrm::InsertPage (this=0x2927a40, pPrevPage=0x2927730, bFtn=0 '\000') 
at /data/lo/core_3_5/sw/source/core/layout/pagechg.cxx:1348
#29 0x00007fce48ef9d24 in SwFrm::GetNextLeaf (this=0x2927a40, eMakePage=MAKEPAGE_INSERT) at 
/data/lo/core_3_5/sw/source/core/layout/flowfrm.cxx:1046
#30 0x00007fce48ef9673 in SwFrm::GetLeaf (this=0x2927a40, eMakePage=MAKEPAGE_INSERT, bFwd=1 
'\001') at /data/lo/core_3_5/sw/source/core/layout/flowfrm.cxx:844
#31 0x00007fce48efc0f8 in SwFlowFrm::MoveFwd (this=0x2927af8, bMakePage=1 '\001', bPageBreak=0 
'\000', bMoveAlways=0 '\000') at /data/lo/core_3_5/sw/source/core/layout/flowfrm.cxx:1917
#32 0x00007fce48eead03 in SwCntntFrm::MakeAll (this=0x2927a40) at 
/data/lo/core_3_5/sw/source/core/layout/calcmove.cxx:1704
#33 0x00007fce48ee4559 in SwFrm::PrepareMake (this=0x2927a40) at 
/data/lo/core_3_5/sw/source/core/layout/calcmove.cxx:386
#34 0x00007fce48c1a036 in SwFrm::Calc (this=0x2927a40) at 
/data/lo/core_3_5/sw/source/core/inc/frame.hxx:1054
#35 0x00007fce48eea578 in SwCntntFrm::MakeAll (this=0x2927920) at 
/data/lo/core_3_5/sw/source/core/layout/calcmove.cxx:1588
#36 0x00007fce48ee4559 in SwFrm::PrepareMake (this=0x2927920) at 
/data/lo/core_3_5/sw/source/core/layout/calcmove.cxx:386
#37 0x00007fce48c1a036 in SwFrm::Calc (this=0x2927920) at 
/data/lo/core_3_5/sw/source/core/inc/frame.hxx:1054
#38 0x00007fce490b01f8 in SwTxtFrm::GetFormatted (this=0x2927920, bForceQuickFormat=false) at 
/data/lo/core_3_5/sw/source/core/text/txtfrm.cxx:2130
#39 0x00007fce4902bff8 in SwTxtFrm::GetCharRect (this=0x2927920, rOrig=..., rPos=SwPosition (node 
9, offset 0), pCMS=0x7fff460fdbb0) at /data/lo/core_3_5/sw/source/core/text/frmcrsr.cxx:215
#40 0x00007fce48c10c04 in SwCrsrShell::UpdateCrsr (this=0x29139f0, eFlags=4, bIdleEnd=0 '\000') 
at /data/lo/core_3_5/sw/source/core/crsr/crsrsh.cxx:1681
#41 0x00007fce48c13235 in SwCrsrShell::ShGetFcs (this=0x29139f0, bUpdate=0 '\000') at 
/data/lo/core_3_5/sw/source/core/crsr/crsrsh.cxx:2096
#42 0x00007fce48eb5e0b in SwFEShell::ShGetFcs (this=0x29139f0, bUpdate=0 '\000') at 
/data/lo/core_3_5/sw/source/core/frmedt/fews.cxx:326
#43 0x00007fce495f0f64 in SwView::Activate (this=0x292e8e0, bMDIActivate=1 '\001') at 
/data/lo/core_3_5/sw/source/ui/uiview/view1.cxx:81
#44 0x00007fce697b6a21 in SfxShell::DoActivate_Impl (this=0x292e8e0, pFrame=0x28b25c0, bMDI=1 
'\001') at /data/lo/core_3_5/sfx2/source/control/shell.cxx:639


PS: all those __memcpy_ssse3_back in the bug attached valgrind.log look
like positives?


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.