Bug 72204 - FILEOPEN: RTF import of table in text box - crash
Summary: FILEOPEN: RTF import of table in text box - crash
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium major
Assignee: Miklos Vajna
URL:
Whiteboard: target:4.3.0 target:4.2.0.2
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-01 17:57 UTC by Andras Timar
Modified: 2013-12-20 17:13 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Table in textbox RTF (66.42 KB, application/rtf)
2013-12-01 17:57 UTC, Andras Timar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andras Timar 2013-12-01 17:57:05 UTC
Created attachment 90059 [details]
Table in textbox RTF

I use 4.3 master, 07c287d01e02e97df76a02a9a35238915d26c01b.


Program received signal SIGSEGV, Segmentation fault.
0x00002aaaccfe6a80 in writerfilter::rtftok::RTFSdrImport::applyProperty (this=0x1b64b50, xShape=empty uno::Reference, aKey="rotation", 
    aValue="0") at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtfsdrimport.cxx:193
193	        xPropertySet->setPropertyValue("RotateAngle", uno::makeAny(sal_Int32(NormAngle360(nRotation * -1))));
(gdb) bt
#0  0x00002aaaccfe6a80 in writerfilter::rtftok::RTFSdrImport::applyProperty (this=0x1b64b50, xShape=empty uno::Reference, aKey="rotation", 
    aValue="0") at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtfsdrimport.cxx:193
#1  0x00002aaaccfec816 in writerfilter::rtftok::RTFSdrImport::appendGroupProperty (this=0x1b64b50, aKey="rotation", aValue="0")
    at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtfsdrimport.cxx:707
#2  0x00002aaaccfacf3d in writerfilter::rtftok::RTFDocumentImpl::popState (this=0x1b58450)
    at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtfdocumentimpl.cxx:3987
#3  0x00002aaaccff9bd0 in writerfilter::rtftok::RTFTokenizer::resolveParse (this=0x1b65ae0)
    at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtftokenizer.cxx:106
#4  0x00002aaaccf93ed1 in writerfilter::rtftok::RTFDocumentImpl::resolve (this=0x1b58450, rMapper=...)
    at /home/timar/libreoffice-master/writerfilter/source/rtftok/rtfdocumentimpl.cxx:632
#5  0x00002aaacd110788 in RtfFilter::filter (this=0x1b39890, aDescriptor=uno::Sequence of length 12 = {...})
    at /home/timar/libreoffice-master/writerfilter/source/filter/RtfFilter.cxx:127
#6  0x00002aaaadab3df1 in SfxObjectShell::ImportFrom (this=0x1a8bf50, rMedium=..., bInsert=false)
    at /home/timar/libreoffice-master/sfx2/source/doc/objstor.cxx:2253
Comment 1 Thomas van der Meulen [retired] 2013-12-02 20:04:22 UTC
Thank you for your bug report, I can reproduce this bug running 
Version: 4.2.0.0.beta1
Build ID: f4ca7b35f580827ad2c69ea6d29f7c9b48ebbac7
OS: Mac osx 10.9.
Comment 2 Miklos Vajna 2013-12-20 15:24:51 UTC
Right, the code assumes every XShapes implement XShape, which is not true (SwXDrawPage is such an example). I'll take care of this.
Comment 3 Commit Notification 2013-12-20 16:01:03 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=3e199f81473d1f85a75238ac03d38a220f3ab818

fdo#72204 RTF import: fix crash on rotated, but not imported groupshape



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.
Comment 4 Commit Notification 2013-12-20 17:12:54 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-4-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=c3d1e74fa1de47805ee37748bf3bce1fd2594772&h=libreoffice-4-2

fdo#72204 RTF import: fix crash on rotated, but not imported groupshape


It will be available in LibreOffice 4.2.

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.
Comment 5 Miklos Vajna 2013-12-20 17:13:23 UTC
Marking as resolved, libreoffice-4-1 is not affected.