Issue 88307 - crash on closing document (chart was canceled)
Summary: crash on closing document (chart was canceled)
Status: CLOSED FIXED
Alias: None
Product: General
Classification: Code
Component: chart (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: Mac Mac OS X, all
: P3 Trivial (vote)
Target Milestone: ---
Assignee: oc
QA Contact: issues@graphics
URL:
Keywords: aqua
Depends on:
Blocks:
 
Reported: 2008-04-15 19:00 UTC by b.osi.ooo
Modified: 2013-02-24 21:19 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description b.osi.ooo 2008-04-15 19:00:47 UTC
How to reproduce:
- open writer
- insert table
- while cursor is inside table: insert->object->chart
- press cancel on chart dialog
- file->close: select cancel, when asked for saving
-> crash

Autotest would be w_updt.bas testcase: tInsertObjectChart
Comment 1 b.osi.ooo 2008-04-15 19:01:54 UTC
target, keyword
Comment 2 philipp.lohmann 2008-04-16 10:07:40 UTC
actually it fails for me when closing the office with the following stack:

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0xc738103f
0x95a02eb5 in std::_Rb_tree_increment ()
(gdb) where
#0  0x95a02eb5 in std::_Rb_tree_increment ()
#1  0x2098e648 in SwChartDataProvider::DisposeAllDataSequences ()
#2  0x2098e8c1 in SwChartDataProvider::dispose ()
#3  0x20d58bf1 in SwDocShell::~SwDocShell ()
#4  0x0086e8ff in SfxViewFrame::ReleaseObjectShell_Impl ()
#5  0x00883333 in SfxTopViewFrame::~SfxTopViewFrame ()
#6  0x00882aeb in SfxTopViewFrame::Close ()
#7  0x0085c8e3 in SfxFrame::DoClose_Impl ()
#8  0x0088edf8 in SfxBaseController::dispose ()
#9  0x12e6d239 in framework::Frame::setComponent ()
#10 0x12e6c800 in framework::Frame::close ()
#11 0x12e48ef4 in framework::Desktop::impl_closeFrames ()
#12 0x12e4c1c6 in framework::Desktop::terminate ()
#13 0x000a95a9 in desktop::Desktop::QueryExit ()
#14 0x01b322e8 in ImplWindowFrameProc (pWindow=0x24a54cb0, nEvent=13,
pEvent=0x0) at
/Volumes/Tiger/Users/pl93762/aquavcl07/vcl/source/window/winproc.cxx:2519
#15 0x01cb8e11 in SalFrame::CallCallback (this=0x1ce9efc0, nEvent=13,
pEvent=0x0) at ../../../inc/vcl/salframe.hxx:315
#16 0x01bdc3ca in -[VCL_NSApplication applicationShouldTerminate:]
(self=0x731f260, _cmd=0x922340e8, app=0x731f260) at vclnsapp.mm:210
Comment 3 IngridvdM 2008-04-16 10:57:52 UTC
->tbo,pl: in which version does the crash occur?
Comment 4 philipp.lohmann 2008-04-16 11:43:22 UTC
sorry, for me that was a DEV300m6, nonpro
Comment 5 IngridvdM 2008-06-05 14:57:16 UTC
I checked with dev300m17 unxmacxi.pro and cannot reproduce the crash anymore.
Comment 6 IngridvdM 2008-06-05 14:59:06 UTC
@Thomas, as SwChartDataProvider::DisposeAllDataSequences is your code maybe you
want to have a look at this nevertheless?
Comment 7 IngridvdM 2008-06-05 15:35:56 UTC
uups, I can reproduce with a slightly different scenario:
choose 'discard' instead of 'cancel' in the last step
Comment 8 Mathias_Bauer 2008-06-09 11:28:37 UTC
target 3.1
Comment 9 oc 2008-08-15 13:04:23 UTC
adding cc
Comment 10 thomas.lange 2008-08-15 13:59:46 UTC
Easy to fix.
Basically just replace the line
        const Set_DataSequenceRef_t &rSet = aDataSequences[ pTable ];
in SwChartDataProvider::DisposeAllDataSequences by 
        const Set_DataSequenceRef_t aSet = aDataSequences[ pTable ];
That is use a copy of the STL container and not the original.
The problem with the first solution is that a call-back from ->dispose will
implicitly remove an element of that container and thus the iterator is broken.
Comment 11 oc 2008-08-15 14:55:47 UTC
raising target
Comment 12 thomas.lange 2008-08-18 09:07:07 UTC
Fixed in CWS tl59.

Files changed:
- sw/source/core/unocore/unochart.cxx
Comment 13 thomas.lange 2008-08-19 12:39:53 UTC
TL: Now fixed in CWS tl61 and not in tl51.
Comment 14 thomas.lange 2008-08-20 13:23:29 UTC
.
Comment 15 oc 2008-08-21 10:27:54 UTC
verified in cws_tl61
Comment 16 smith77 2009-04-04 20:59:53 UTC
VERIFAYED ON MASTER VERSION OOo 3.1 - NO PROBLEM FOUND .
Comment 17 thorsten.ziehm 2009-07-20 15:55:23 UTC
This issue is closed automatically and wasn't rechecked in a current version of
OOo. The fixed issue should be integrated in OOo since more than half a year. If
you think this issue isn't fixed in a current version (OOo 3.1), please reopen
it and change the field 'Target Milestone' accordingly.

If you want to download a current version of OOo =>
http://download.openoffice.org/index.html
If you want to know more about the handling of fixed/verified issues =>
http://wiki.services.openoffice.org/wiki/Handle_fixed_verified_issues