Bug 152045 - Saving a DOCX document with a content control in Writer produces a document unreadable in Word
Summary: Saving a DOCX document with a content control in Writer produces a document u...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.5.0.0 alpha0+
Hardware: All All
: medium normal
Assignee: Miklos Vajna
URL:
Whiteboard: target:7.5.0 target:7.4.4
Keywords: bibisected, bisected, filter:docx, regression
Depends on:
Blocks: DOCX-Content_Control
  Show dependency treegraph
 
Reported: 2022-11-14 21:24 UTC by Mike Kaganski
Modified: 2022-12-14 18:36 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
A sample DOCX with a content control (11.74 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2022-11-14 21:24 UTC, Mike Kaganski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Kaganski 2022-11-14 21:24:23 UTC
Created attachment 183596 [details]
A sample DOCX with a content control

Open the attachment (created in Word 2016) in Writer, and save (as DOCX).
The resulting DOCX can't be opened in Word, an error is shown: "Word experienced an error trying to open the file."

Tested with Version: 7.4.3.1 (x64) / LibreOffice Community
Build ID: 3793858a34d8fef5b92f8fee233f97766f05e281
CPU threads: 12; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: zh-CN (ru_RU); UI: en-US
Calc: CL

and with Version: 7.5.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: dbc307ef7c2351cd72e60ef46e647c908379db86
CPU threads: 12; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: en-US (ru_RU); UI: en-US
Calc: CL threaded
Comment 1 Stéphane Guillou (stragu) 2022-11-15 10:23:57 UTC
Tested on Office 365 on Windows 10 professional, the original attachment opens without error, but it errors if it has gone through LO 7.5 before.

Version: 7.5.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 6e66b5d75b4cda0314b64f4d12ef9e4350751470
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

Regression, as 7.4.2.3 doesn't break it:

Version: 7.4.2.3 / LibreOffice Community
Build ID: 382eef1f22670f7f4118c8c2dd222ec7ad009daf
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded
Comment 2 Roman Kuznetsov 2022-11-15 10:55:00 UTC
I bisected this one and got

https://git.libreoffice.org/core/commit/f726fbc2699b05199a8dec3055710a7131e0aad6

https://gerrit.libreoffice.org/c/core/+/141151

Added to CC: Miklos Vajna

Please take a look. Thanks
Comment 3 Commit Notification 2022-11-22 07:06:19 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/017c38a9702da0566ac1ce5d758444e5ff25df9d

tdf#152045 DOCX export: fix empty display text for content control list items

It will be available in 7.5.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:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 4 Roman Kuznetsov 2022-11-29 13:12:30 UTC
Verified in

Version: 7.5.0.0.alpha1+ (X86_64) / LibreOffice Community
Build ID: 5b18eebc2c95321ce7e6edf10f4df81557382a48
CPU threads: 8; OS: Windows 10.0 Build 19043; UI render: Skia/Vulkan; VCL: win
Locale: ru-RU (ru_RU); UI: ru-RU
Calc: threaded

Thanks Miklos!
Comment 5 Commit Notification 2022-12-14 18:36:25 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

https://git.libreoffice.org/core/commit/e77e25e6ac8d4fafa83cf4d1ebeb53fd719c834c

tdf#152045 DOCX export: fix empty display text for content control list items

It will be available in 7.4.4.

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:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.