Issue 41870 - Crash when loading impress doc after opening new impress
Summary: Crash when loading impress doc after opening new impress
Status: CLOSED FIXED
Alias: None
Product: Impress
Classification: Application
Component: ui (show other issues)
Version: 680m75
Hardware: All All
: P2 Trivial (vote)
Target Milestone: OOo 2.0
Assignee: wolframgarten
QA Contact: issues@graphics
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-02-02 09:04 UTC by wolframgarten
Modified: 2005-02-07 15:42 UTC (History)
1 user (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 wolframgarten 2005-02-02 09:04:42 UTC
This is a beta showstopper.
Open a new impress. Then load an existing impress doc: Office crashes. This was
ok in m74.
Comment 1 groucho266 2005-02-02 09:45:15 UTC
As a result of DrawController::dispose() forwarding its call to
SfxBaseController::dispose() the side panes are closed and finally the
ViewShellBase destructor is called.  Closing the side panes results in the
PaneManager removing the associated shells from the stack.  Since this is a
stack we first remove the shells above those belonging to the side pane and
after all is done we add them again.  This adding causes the crash since it is
done at a time when this is not allowed anymore.

The solution will be to remove all sd shells from the shell steck when the
DrawController is disposed.
Comment 2 groucho266 2005-02-02 13:54:44 UTC
Fixed by calling PangeManager::Shutdown(true) and ViewShellManager::Shutdown()
from DrawController::dispose().

The first, PangeManager::Shutdown(true), tells the pane manager to forget about
view shells and windows.  Without the (new) flag set to true it would close the
docking windows and shut down the shells.  This call to Shutdown() is necessary
in order for following calls to the PaneManager, e.g. caused by the SFX closing
the docking windows, not accessing the (then destroyed) shells anymore.

The second, ViewShellManager::Shutdown(), simply takes all sd shells from the
shell stack.  It has been modified to call DrawDocShell::Disconnect() for every
view shell so that the doc shell in its destructor will not access the main view
shell which by then is destroyed.

The two calls to Shutdown() are made only when the DrawController has not been
detached from its view shell.  This indicates a switch from one view to another.
 Taking all shells from the stack would destroy the ViewShellBase also.  But
that would be an error.

Affected files:
PaneManager.hxx         1.5.86.1
PaneManager.cxx         1.11.10.1
DrawController.cxx        1.10.78.1
ViewShellManager.cxx  1.9.10.1
ViewTabBar.cxx            1.3.02.1
Comment 3 groucho266 2005-02-02 17:12:29 UTC
Reopening...
Comment 4 groucho266 2005-02-02 17:12:52 UTC
...reassigning...
Comment 5 groucho266 2005-02-02 17:13:14 UTC
...resolving.
Comment 6 wolframgarten 2005-02-03 09:30:28 UTC
Tested in CWS. Verified.
Comment 7 wolframgarten 2005-02-07 15:42:13 UTC
Tested in master. Closed.