Add the following BASIC macro to My Macros: Sub Goback_to_normal_view Dim document as object Dim dispatcher as object document = ThisComponent.CurrentController.Frame dispatcher = createUnoService("com.sun.star.frame.DispatchHelper") Dim args(0) as new com.sun.star.beans.PropertyValue dispatcher.executeDispatch(document, ".uno:_SwitchViewShell0", "", 0, args()) End Sub Steps: - Start a new HTML document. - Save it. - Switch to View -> HTML Source. - Go to the macro editor (Tools -> Macros -> Organize Macros -> LibreOffice Basic...; find the macro and click Edit). - Run macro from the editor. => There's a crash. See report: http://crashreport.libreoffice.org/stats/crash_details/f084c009-4103-4cd8-bec6-884191626551 There's no crash if the macro is run via Tools -> Macros -> Run Macro... Though sometimes I get "JRE is Defective" error there. Observed using 6.0 master build (dc55f0618cae0e0ec7877eda065cc4b387e16bfb), 5.4.2.2/ Windows 7.
The crash also occurs in 5.3.0.3, but not in 5.2.0.4, so it's a regression. It might be Windows-only.
The trace is somewhat similar to bug 105121's.
(In reply to Aron Budea from comment #2) > The trace is somewhat similar to bug 105121's. Not directly related to bug 105121, but this is a common pattern since the VclPtr conversion to have the GetFocus method of a window called during its dispose, and the GetFocus method tries to set the focus to one of its child controls, which will crash if this particular control was already destructed to this point. There are dozens of similar bugs in Bugzilla. The usual fix we apply in those cases is to add a check inside GetFocus, whether the child is still valid, so you might want to try this (can't do any development myself right now): void SwSrcEditWindow::GetFocus() { + if (m_pOutWin) m_pOutWin->GrabFocus(); }
That's it, thanks for the hint, Maxim!
Aron Budea committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=a83a0345e493b928b0b0b93bf106ddb71df69893 tdf#113548: another case of crash in GrabFocus during dispose It will be available in 6.0.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
It was Windows-only, too.