Bug 146955 - SAXParseException: '[word/footnotes.xml line 2] after RT save of DOCX - on open by LO and not by MSO
Summary: SAXParseException: '[word/footnotes.xml line 2] after RT save of DOCX - on op...
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected) release
Hardware: All All
: medium normal
Assignee: Not Assigned
Whiteboard: target:7.4.0
Keywords: bibisected, bisected, regression
: 142731 (view as bug list)
Depends on:
Blocks: DOCX-SAXParse
  Show dependency treegraph
Reported: 2022-01-24 09:44 UTC by Telesto
Modified: 2022-08-14 16:23 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:
Regression By:

sample file (121.25 KB, application/vnd.oasis.opendocument.text)
2022-01-25 11:21 UTC, Xisco Faulí

Note You need to log in before you can comment on or make changes to this bug.
Description Telesto 2022-01-24 09:44:32 UTC
SAXParseException: '[word/footnotes.xml line 2]: unknown error', Stream 'word/footnotes.xml' on file exported by LibreOffice

Steps to Reproduce:
1. Open the attached file
2. Save As DOCX
3. Close the document
4. Open the document

FWIW: this happens with the attached file exported with 7.1b1 (imported with 7.4). If still present with recent versions I can't asses, blocked by bug 146875

Actual Results:

Expected Results:
No SAXParseException

Reproducible: Always

User Profile Reset: No

Additional Info:
Version: (x64) / LibreOffice Community
Build ID: 4a388f5e01ebb5a512931d11e48c4380382239c8
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: nl-NL (nl_NL); UI: en-US
Calc: CL
Comment 1 Xisco Faulí 2022-01-24 09:58:44 UTC Comment hidden (obsolete)
Comment 2 Telesto 2022-01-24 10:18:40 UTC
(In reply to Xisco Faulí from comment #1)
> Hi Telesto,
> you forgot to attach the file

Didn't fit.. Link to file:

Comment 3 Timur 2022-01-25 10:38:03 UTC
No repro 7.0, regression in 7.2, still in 7.4+.
Comment 4 Xisco Faulí 2022-01-25 11:16:40 UTC
Regression introduced by:


author	László Németh <nemeth@numbertext.org>	2021-02-10 00:12:52 +0100
committer	László Németh <nemeth@numbertext.org>	2021-02-12 18:27:31 +0100
commit 9b39ce0e66acfe812e1d50e530dc2ccdef3e1357 (patch)
tree f1bb0d9c24dbe6a40e82837f0ff5632a90799530
parent 3380163bc0fb9dab7f289cc36b0eeb0c9b3ddaa9 (diff)
tdf#76260 DOCX import: fix slow footnote import

Bisected with: bibisect-linux64-7.2

Adding Cc: to László Németh
Comment 5 Xisco Faulí 2022-01-25 11:21:15 UTC
Created attachment 177766 [details]
sample file
Comment 6 Timur 2022-01-25 11:36:51 UTC Comment hidden (obsolete)
Comment 7 Xisco Faulí 2022-01-25 11:47:21 UTC
(In reply to Timur from comment #6)
> Xisco, can you please explain how you minimized the document?

I just removed the images with the zip manager
Comment 8 Xisco Faulí 2022-05-02 14:53:43 UTC
Dear László Németh ,
This bug has been in ASSIGNED status for more than 3 months without any
activity. Resetting it to NEW.
Please assign it back to yourself if you're still working on this.
Comment 9 László Németh 2022-05-26 18:26:57 UTC
Commit description:

tdf#146955 DOCX import: fix SAX exception with footnotes

(Likely broken) DOCX documents exported by Writer raised a SAX
exception, when PopFootOrEndnote() tried to access to a
not-existent footnote, because PushFootOrEndnote() failed to
create that.

Note: the original ODT contains hundreds of frames, and
these and the text content of the document have been put
into the TOC section during Writer's DOCX export, resulting a
broken document.

Regression from commit 9b39ce0e66acfe812e1d50e530dc2ccdef3e1357
"tdf#76260 DOCX import: fix slow footnote import".
Comment 10 Commit Notification 2022-05-26 18:27:40 UTC
László Németh committed a patch related to this issue.
It has been pushed to "master":


tdf#146955 DOCX import: fix SAX exception with footnotes

It will be available in 7.4.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:

Affected users are encouraged to test the fix and report feedback.
Comment 11 NISZ LibreOffice Team 2022-05-31 08:41:27 UTC
Verified in:
Version: (x64) / LibreOffice Community
Build ID: dfd5081ff3973d5d0f216b06dda6360fa490cc9c
CPU threads: 8; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win
Locale: hu-HU (hu_HU); UI: hu-HU
Calc: CL
Comment 12 Gabor Kelemen (allotropia) 2022-08-14 16:23:23 UTC
*** Bug 142731 has been marked as a duplicate of this bug. ***