Read-Error. Format error discovered in the file in sub-document content.xml at 2,168126(row,col).
please upload test file then tell your LibO version and O/S status NEEDINFO revert it to UNCONFIRMED when you answer these questions
Created attachment 121001 [details] odt file
*** Bug 96323 has been marked as a duplicate of this bug. ***
dstrzele/Paolo: Any chance of getting a version of the document one step before the corruption happens, so we can reproduce the buggy saving? This will help us a lot in fixing this. Thanks.
Maxim Monastirsky, i'm sorry, but I have no chance: the bug occurs randomly. Today I changed the document three times: twice it went well, once was corrupt. I suspect that my document has problems, because the frequency with which it is corrupt is unacceptable. (With Writer: Version 3 <-> 4 I never had problems)
(In reply to Paolo Meozzi from comment #5) > i'm sorry, but I have no chance: the bug occurs randomly. That's unfortunate. Adding Michael to CC. Maybe he has an idea why is this duplicate fo:background-color="transparent" added to styles.
Created attachment 121213 [details] Document template and macro
I found a pattern! But I do not know how useful. The problem happens when I paste code fragment from Visual Studio (2013), but only when using a particular document template. Since version 4.x (I think), the pasted code from VS maintains the white background and thus change the background that I have assigned to the style "code" in my documents. For this reason I created a macro that applies the style and sets the background transparent the selected text. Everything works fine except in one case: 1) I paste a snippet of code from VS (OK) 2) applying macro (OK) 3) paste the new fragment of VS within the code already formatted. (OK) 4) apply the macro again (only) to the fragment just pasted (oh oh!) Save to disk ... and the document is corrupt: the background is set twice, transparent and white. I added the document templates and macros that format text.
(In reply to Paolo Meozzi from comment #8) > I found a pattern! But I do not know how useful. Very useful! I reproduced exactly with your steps (but with VS 2015). Version: 5.2.0.0.alpha0+ Build ID: 6fd3f3caad1a559165dc9332249cbd0d84930775 Threads 1; Ver: Windows 6.1; Render: default; TinderBox: Win-x86@62-merge-TDF, Branch:MASTER, Time: 2015-12-08_23:31:11
Created attachment 121484 [details] previously saved document Does this help?
*** Bug 97360 has been marked as a duplicate of this bug. ***
i can't reproduce the problem... but i'm highly suspicious of this commit: commit f880962f5bf26bfaef06bd3f9e67e2d901a2e74c Author: Zolnai Tamás <zolnaitamas2000@gmail.com> AuthorDate: Wed Mar 18 10:25:05 2015 +0100 Char highlight: ODT filters Export merges the two background attribute. ... which adds another property that exports to the offending fo:background-color attribute, and was added in LO 5.0... that's just too much of a coincidence... ... alright this reproduces the problem from scratch: Sub Main c = ThisComponent.Text.createTextCursor() c.setString("foo bar baz") c.goRight(4, false) c.goRight(3, true) msgbox(c.getString()) c.CharBackColor = 0 c.CharHighlight = 0 c.CharBackTransparent = 1 End Sub
fixed on master
Michael Stahl committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=8dadefc35f8b33648fb6adbdaca75ea52b2705db xmloff: tdf#96147: ODF export: fix duplicate fo:background-color It will be available in 5.2.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.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-5-0": http://cgit.freedesktop.org/libreoffice/core/commit/?id=e92dcab1407fa26fc5ee68d0b626b87bc04f1b3b&h=libreoffice-5-0 xmloff: tdf#96147: ODF export: fix duplicate fo:background-color It will be available in 5.0.6. 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.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-5-0-5": http://cgit.freedesktop.org/libreoffice/core/commit/?id=89aa74dd903a7919b33982bc2efc74c8ec902fdc&h=libreoffice-5-0-5 xmloff: tdf#96147: ODF export: fix duplicate fo:background-color It will be available in 5.0.5. 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.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-5-1": http://cgit.freedesktop.org/libreoffice/core/commit/?id=e2383402d4cab93f4003e03912700a00525b7d4c&h=libreoffice-5-1 xmloff: tdf#96147: ODF export: fix duplicate fo:background-color It will be available in 5.1.1. 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.