Apache OpenOffice (AOO) Bugzilla – Full Text Issue Listing |
Summary: | Crash on using XDesktop.terminate() with the bean | ||||||
---|---|---|---|---|---|---|---|
Product: | App Dev | Reporter: | oh <oliverhopt> | ||||
Component: | api | Assignee: | oh <oliverhopt> | ||||
Status: | CLOSED NOT_AN_OOO_ISSUE | QA Contact: | issues@api <issues> | ||||
Severity: | Trivial | ||||||
Priority: | P3 | CC: | issues | ||||
Version: | 3.3.0 or older (OOo) | ||||||
Target Milestone: | --- | ||||||
Hardware: | Sun | ||||||
OS: | Solaris | ||||||
Issue Type: | DEFECT | Latest Confirmation in: | --- | ||||
Developer Difficulty: | --- | ||||||
Attachments: |
|
Description
oh
2003-04-08 15:00:08 UTC
Created attachment 5530 [details]
Tar of 4 java files as showcase
Sorry - but this isn't a bug inside office. a) The code you attached creates a frame outside the global frame tree of the office with the desktop as root. So a Desktop.terminate() can't detect it. But at the end of office termination a global object pool recognizes, that there is at least one document structure and try to release it ... but it's to late. Most of the office internal components are already deinitialized and so this request will run into an access violation. Solution: If an internal script creates own ressources (especialy document frames) outside the normal uses cases - it has to release such private structures BEFORE it calls terminate(). Otherwhise the results will be undefined. Or it has to use the API right, to make frames part of the already mentioned frame tree. (see e.g. XFrame.findFrame("_blank",0)) for further informations) b) The only bug I've found (and filed another internal bug report for that) was, that the used TerminateListener runs into it's finalize() method immediatly after it was added to the desktop listener container. The remote reference (which exists inside the desktop container) was valid ... but the client reference was not hold by the client proxy of the uno bridge. So the listener was not realy added. But that was not a problem for the attached code - because this terminate listener will be disabled before terminate() will be called. c) At least the attached code does not handled an already closed office connection. So it tries to terminate it more then once - because the method closeConnection() is used at more then one code places. So the code has to react for multiple RuntimeException's - especialy DisposedException's. Please read the available SDK Manual on openoffice.org or contact Jürgen Schmidt / Michael Hönnig for further informations on this thema. Regards Andreas Schlüns . I found out that the TerminateListener seems to work well with OpenOffice 1.1 Beta and JRE 1.4.1 (build 1.4.1-b21). I did not have any case where the listener was not called. JRE 1.4.0 does defenetly not work. Kind regards Oliver JA: closing as invalid . |