[Libreoffice] [REVIEW] RTF import patches for 3-4

Miklos Vajna vmiklos at frugalware.org
Mon Jul 11 09:48:08 PDT 2011


On Mon, Jul 11, 2011 at 11:45:33AM +0100, Michael Meeks <michael.meeks at novell.com> wrote:
> Hi Cedric,
> 
> On Fri, 2011-07-08 at 15:06 +0200, Cedric Bosdonnat wrote:
> > Here are two patches to review for the 3.4 branch. I know it's stupid to
> > hack the RTF import filter... but the new one won't be in 3.4 ;)
> 
> 	The second patch - basic-handling-of-lines looks fine to me - ack'd for
> -3-4. The first is a bit more interesting and/or requires some more
> insight from Miklos I guess.
> 
> 	I don't see any other code doing this:
> 
> +        // Remove the properties that have been parsed before in the paragraph
> +        GetAttrStack().pop_back();

Hi Michael,

[ Just from that it looks incorrect: if we have a stack that is pushed and
popped after each { and } (as RTF requires it), then doing a pop_back()
to reset the properties will cause a problem at the end (when the
importer tries to pop the last - already popped - element).

But given that I'm not really familiar with the old code and I'm sure
the above reasoning would result in an inmediate crash, just ignore it.
:) ]

Anyway, is the bug private on purpose? From the patches looks like it
has something with the old-style shapes for which I have no test
documents, as Word97+ no longer emits that syntax. At the moment these
Word 6.0/95-style drawing are completely ignored by the new importer -
in case you think it would not be a waste of time to support the old
syntax as well, then I would be interested in the test document.

Thanks.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20110711/92584077/attachment.pgp>


More information about the LibreOffice mailing list