Summary: | LibreOffice crashes when Basic calls an insert object method | ||
---|---|---|---|
Product: | LibreOffice | Reporter: | Dorange-Pattoret Didier <ddorange> |
Component: | BASIC | Assignee: | Not Assigned <libreoffice-bugs> |
Status: | CLOSED WORKSFORME | QA Contact: | |
Severity: | blocker | ||
Priority: | medium | CC: | atayoohoo, jbfaure, LibreOffice |
Version: | 3.3.2 release | ||
Hardware: | x86 (IA32) | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: |
File with right work...
test document to insert formula object by macro stack trace on Mac OSX |
(In reply to comment #0) > Created an attachment (id=41571) [details] > File with right work... > > This bug comes with Mandriva 2010.2 or MacOSX and OOO330m18 Build 4 (LibreO > RC2). > > Install Dmaths : www.dmaths.org/addons/DmathsAddon.oxt > > First formula write 1/2 and then F10 (F8 Mac) or red M icon in the toolbar. > then write +1/3 and then F10 (F8 Mac) or red M icon in the toolbar. > > Instead you get 1 over 2 + 1 over 3 and the right formula, it crashes. > > Library Dmaths > Modul named module1 > Line 1543 : > Objets=oTextCursor2.createContentEnumeration("com.sun.star.text.TextContent") > > This line works very fine since OOo2.4 .... I can't reproduce the crash... neither on 3.3 nor master branch. Could you please extract some minimal basic macro showing the bug? It would be helpful for you to provide some more infos, see http://wiki.documentfoundation.org/BugReport Hi all, Confirming reproducible crash on Mac OSX 10.6.6 with LibO 3.3.1 and using the following Sub routine provided by Didier Dorange : /Sub bugMac oViewCursor = ThisComponent.getCurrentController().getViewCursor() oTextCursor=oViewCursor.Text.createTextCursorByRange(oViewCursor) obj=ThisComponent.CreateInstance("com.sun.star.text.TextEmbeddedObject") obj.CLSID="078B7ABA-54FC-457F-8551-6147e776a997" obj.AnchorType=com.sun.star.text.TextContentAnchorType.AS_CHARACTER oTextCursor.Text.insertTextContent(oTextCursor, obj, true) obj.embeddedObject.formula="1 over x" obj.dispose End Sub/ Test document provided. Alex Created attachment 44198 [details]
test document to insert formula object by macro
test document to insert formula object by macro
Created attachment 44199 [details]
stack trace on Mac OSX
trace report provided by Apple Crash reporter
changing title to better reflect behaviour removing needinfo keyword changing platform to OSX 1) If I comment the following line : obj.dispose, the formula is inserted. 2) But, If I try to remove it (with "Backspace") LibreOffice crashes again. 3) If I copy and paste the formula, I can remove the pasted one but not the first. May be a problem with memory when I try to destroy the object ? Same bug with debian squeeze + LibO 3.3.2 OOO330m19 (Build:202-202-8) + dmaths 3.4.0.0 Same bug with Ubuntu 10.10 + LibO 3.3.2 OOO330m19 (Build:202-202-8) + dmaths 3.4.0.4 Dmaths is for me essemtial. I choose to use OOo3.2.1 back In LibreOffice 3.4.0 DEV300m103, the application does not crash. When obj.dispose is called, Error: File /home/abecker/libreoffice/bootstrap/comphelper/source/container/embeddedobjectcontainer.cxx, Line 1156: Failed to remove object from storage! appears in the terminal. It seems like someone added a try-catch block. I found out that the function FSStorage::removeElement throws an io::IOException() exception. Hello, I think you can close this bug because the problem comes with the embeddedobject property wich has been changed. The below code works fine with Libreoffice 3.3 and 3.4 I wrote obj.model.formula instead of obj.embeddedObject.formula Best regards. /Sub bugMac oViewCursor = ThisComponent.getCurrentController().getViewCursor() oTextCursor=oViewCursor.Text.createTextCursorByRange(oViewCursor) obj=ThisComponent.CreateInstance("com.sun.star.text.TextEmbeddedObject") obj.CLSID="078B7ABA-54FC-457F-8551-6147e776a997" obj.AnchorType=com.sun.star.text.TextContentAnchorType.AS_CHARACTER oTextCursor.Text.insertTextContent(oTextCursor, obj, true) obj.model.formula="1 over x" obj.dispose End Sub/ (In reply to comment #12) Closing due to comment closing. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.
Created attachment 41571 [details] File with right work... This bug comes with Mandriva 2010.2 or MacOSX and OOO330m18 Build 4 (LibreO RC2). Install Dmaths : www.dmaths.org/addons/DmathsAddon.oxt First formula write 1/2 and then F10 (F8 Mac) or red M icon in the toolbar. then write +1/3 and then F10 (F8 Mac) or red M icon in the toolbar. Instead you get 1 over 2 + 1 over 3 and the right formula, it crashes. Library Dmaths Modul named module1 Line 1543 : Objets=oTextCursor2.createContentEnumeration("com.sun.star.text.TextContent") This line works very fine since OOo2.4 ....