manually changing content.xml > invalid xml.. but why

Eike Rathke erack at redhat.com
Wed Sep 4 18:26:34 UTC 2019


Hi Cor,

On Wednesday, 2019-09-04 19:45:33 +0200, Cor Nouws wrote:

> So I try to remove from the content.xml.
> This results in invalid xml file.. that LO needs to repair on opening.
> Already the slightest change in the xml file (adding a space in string
> "foo") makes the file invalid.

How do you re-zip the file? Best is to freshen the zip with just the
content.xml to keep the original file order and compression, i.e. the
'mimetype' file MUST be the first entry in the zip archive and MUST NOT
be compressed. So,

  zip -f filename.ods content.xml

should do. If that doesn't help then it's something different ("invalid
xml" is a vague description).

  Eike

-- 
GPG key 0x6A6CD5B765632D3A - 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20190904/f7b9a72c/attachment.sig>


More information about the LibreOffice mailing list