Bug 114314 - Draw filter export of specific ODG to PDF/A-1a format crashes LO and system
Summary: Draw filter export of specific ODG to PDF/A-1a format crashes LO and system
Status: RESOLVED INSUFFICIENTDATA
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
4.3.7.2 release
Hardware: x86-64 (AMD64) Linux (All)
: medium critical
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:pdf
Depends on:
Blocks: PDF-Export
  Show dependency treegraph
 
Reported: 2017-12-07 15:32 UTC by Chris Piker
Modified: 2023-04-17 03:20 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Large format Draw single page poster (6.90 MB, application/vnd.oasis.opendocument.graphics)
2017-12-07 15:35 UTC, Chris Piker
Details
Output of soffice --backtrace >> backtrace.log (715 bytes, text/plain)
2017-12-07 15:38 UTC, Chris Piker
Details
File referenced in backtrace.log (3.80 KB, text/plain)
2017-12-07 15:40 UTC, Chris Piker
Details
Xorg backtrace (1.59 KB, text/plain)
2017-12-07 17:57 UTC, Chris Piker
Details
ODG exported to PDF embedded fonts, Hybrid format with embedded .ODG (6.93 MB, application/pdf)
2017-12-07 19:44 UTC, V Stuart Foote
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Piker 2017-12-07 15:32:01 UTC
Description:
The attached PDF crashes all of X-Windows when the Convert to PDF option is selected.  The exact same behavior is observed on three different computers:

  Linux Mint 18.1, Libreoffice-draw (5 series, don't know exact version), NVidia 630
  Linux Mint 18.1, Libreoffice-draw (5 series, don't know exact version), Intel Mobile
  Linux CentOS 6.9 Libreoffice-draw (4.3.7.2), NVida ???

On CentOS problem affects both Gnome and KDE desktops

To reproduce this problem simply load the attached file into Libreoffice Draw and select the following options for PDF export:

  General:  * Range All
            * Lossless compression
            * PDF/A-1a
            * View After Export

  Initial View:  * Page Only

  User Interface:  * Display document after export

  Links:           (No options selected)

  Security:        (No options selected)

This is my presentation, which has to get submitted in PDF format today so I'm understandably distressed.

Steps to Reproduce:
1. Use File open to load the attached file (agu_2017_poster-0.6.odg) into Libreoffice

2. Select Export as PDF

3. select the following options for PDF export

  General:  * Range All
            * Lossless compression
            * PDF/A-1a
            * View After Export

  Initial View:  * Page Only

  User Interface:  * Display document after export

  Links:           (No options selected)

  Security:        (No options selected)


Actual Results:  
Application works for a bit then takes out entire desktop.

Expected Results:
Should have produced a PDF


Reproducible: Always


User Profile Reset: Yes


OpenGL enabled: Yes

Additional Info:
Version: 4.3.7.2
Build ID: 4.3.7.2-2.el6_9.1

(Also affects current version on Linux Mint 18.1, it's something in the 5 series)


User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Firefox/52.0
Comment 1 Chris Piker 2017-12-07 15:35:03 UTC
Created attachment 138279 [details]
Large format Draw single page poster
Comment 2 Chris Piker 2017-12-07 15:38:27 UTC Comment hidden (obsolete)
Comment 3 Chris Piker 2017-12-07 15:40:07 UTC Comment hidden (obsolete)
Comment 4 Chris Piker 2017-12-07 15:54:09 UTC
On Windows 7 virtual machine with all acceleration turned off exporting to PDF using LibreOffice 5, the display does not crash of course, but the output PDF is blank.
Comment 5 Chris Piker 2017-12-07 17:57:14 UTC
Created attachment 138283 [details]
Xorg backtrace

Found the bug trigger is selecting PDF-A/1a in the export options.  Here's the X server backtrace
Comment 6 V Stuart Foote 2017-12-07 19:44:32 UTC
Created attachment 138284 [details]
ODG exported to PDF embedded fonts, Hybrid format with embedded .ODG

No issue opening and exporting to PDF with Windows 10 Ent 64-bit en-US (ver 1709)
Version: 5.4.3.2 (x64)
Build ID: 92a7159f7e4af62137622921e809f8546db437e5
CPU threads: 8; OS: Windows 6.19; UI render: default; 
Locale: en-US (en_US); Calc: group

Reveiwing meta.xml of the .ODG shows it to be prepared with LibreOffice 5.1.6.2 64 bit Linux.
 
Clearing defaults for Export to PDF and using just lossless checkbox and selecting a Hybrid PDF (embed ODF file) produces a readable PDF with fonts embedded from the document. Resulting PDF can be reopened into LibreOffice pulling out the embedded ODF.

So, this could be an issue with the PDF/A-1a format export to PDF.

Attaching the resulting PDF (if you are trying to get it printed for AGU)
Comment 7 Chris Piker 2017-12-07 20:33:20 UTC
Wow, that was very generous of you.  Thanks a lot!  The PDF has been sent to the printer.  

I know I'm generalizing here, but open source community never ceases to amaze me.
--
piker
Comment 8 tommy27 2017-12-08 04:37:20 UTC
@Chris
did you upgrade the obsolete 4.3.7.2 release you are using to latest LibO 5.4.7.2 version?

thousands of bugs have been fixed meanwhile so it's worth it.
Comment 9 Chris Piker 2017-12-08 04:58:58 UTC
The systems we use at work are managed by the group's system administrator, so we're stuck with CentOS 6.9 and whatever packages it provides for a little bit longer, at least until a few higher priority items are cleared from the schedule.

At home I'm running Mint 18.1 to avoid python3 until my current project is over. 

So unless 5.4.7.2 bug fixes are back ported, I won't see them for a while yet.
Comment 10 Xavier Van Wijmeersch 2017-12-08 15:27:27 UTC
I did a test with only PDF/A-1a and the system hangs and needed a cold restart off my pc. So I agree with the comment6 'So, this could be an issue with the PDF/A-1a format export to PDF.'
Comment 11 Buovjaga 2017-12-17 16:44:40 UTC
(In reply to Xavier Van Wijmeersch from comment #10)
> I did a test with only PDF/A-1a and the system hangs and needed a cold
> restart off my pc. So I agree with the comment6 'So, this could be an issue
> with the PDF/A-1a format export to PDF.'

Let's set to NEW, then. I am assuming Xavier used 5.4 or 6.0 to test.

Chris: on the topic of newer versions, you might try AppImages: http://libreoffice.soluzioniopen.com/
Comment 12 Michael Meeks 2017-12-19 09:28:51 UTC
Crashing X should never happen - and is outside of our control / the scope of LibreOffice - also:

[314267.152] (EE) 3: /usr/lib64/xorg/modules/drivers/nvidia_drv.so (0x7f934d8da000+0xb6d52) [0x7f934d990d52]

Is that the proprietary NVidia driver. I would strongly favour notourbug if this cannot be replicated elsewhere.

Thanks for reporting.
Comment 13 Buovjaga 2017-12-19 12:29:03 UTC
(In reply to Michael Meeks from comment #12)
> Is that the proprietary NVidia driver. I would strongly favour notourbug if
> this cannot be replicated elsewhere.

In the description Intel Mobile is mentioned.

Xavier: how about you?
Comment 14 Chris Piker 2017-12-19 16:50:45 UTC
On a Windows 7 virtual machine with both 2-D and 3-D acceleration turned off, the output is blank, though it doesn't crash the virtual machine environment.  

Also libreoffice 5.1.6.2 crashes hard when exporting the file to PDF though it doesn't take out the X-server when running with the following video setup:

$ sudo lshw -c video
  *-display              
       description: VGA compatible controller
       product: Intel Corporation
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       version: 02
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915_bpo latency=0
       resources: irq:277 memory:d0000000-d0ffffff memory:c0000000-cfffffff ioport:f000(size=64

Maybe there's more than one bug interacting to produce the observed results on NVidia, but Libreoffice still can't produce a PDF-A even if it doesn't take out the xserver.
Comment 15 Michael Meeks 2018-01-02 11:59:28 UTC
Consider re-prioritizing; this appears to be an issue that affects some small subset of documents (like the one attached), the hard crash is an Xorg bug so where to go.

It would be good to minimize the draw single-page poster to capture only the element that causes this issue - presumably some very unusual (perhaps generated) image or somesuch: can we bisect the document into pieces and create a minimal document that reproduces this ? It is rather a pretty document having said that - but large). 

Thanks !
Comment 16 Buovjaga 2018-01-02 13:39:58 UTC
Yeah the highest priority was a mis-step, correcting. Severity stays as it describes the awful effects.
Comment 17 Julien Nabet 2019-03-09 10:59:49 UTC
On pc Debian x86-64 with master sources updated today + enable-dbgutil (default UI Render, VCL = gtk3 + Radeon RX570), I don't reproduce crash but had:
- a dialog box with title "Problems during PDF Export" + entry "Transparencies removed"
Some objects were converted to an image in order to remove transparencies, ...

In console, I got:
- a lot of these:
warn:legacy.osl:12073:12073:vcl/source/gdi/pdfwriter_impl.cxx:10750: document structure in disorder !

clicking OK in dialog, I got on console:
! SyncTeX Error : No file?
warn:legacy.osl:12073:12073:svx/source/dialog/rulritem.cxx:675: Wrong MemberId
warn:legacy.tools:12073:12073:sfx2/source/control/statcach.cxx:387: setting state of dirty message
warn:vcl.gdi:12073:12073:vcl/headless/svpgdi.cxx:125: unsupported SvpSalGraphics::blendAlphaBitmap case
warn:sd.core:12073:12073:sd/source/core/PageListWatcher.cxx:96: ImpPageListWatcher::GetSdPage(PageKind::Standard): page number 1 >= 1
warn:vcl:12073:12073:vcl/source/window/winproc.cxx:844: ImplHandleKey: Keyboard-Input is sent to a frame without focus
warn:vcl:12073:12073:vcl/source/window/winproc.cxx:844: ImplHandleKey: Keyboard-Input is sent to a frame without focus

but no crash.
Comment 18 QA Administrators 2021-03-09 03:44:13 UTC Comment hidden (obsolete)
Comment 19 Ezinne 2021-08-15 23:51:14 UTC
This bug is still present in:


Version: 7.3.0.0.alpha0+ / LibreOffice Community
Build ID: 7c1bad415ae48635dc67041c413bb7b76a530c22
CPU threads: 8; OS: Linux 5.8; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2021-07-05_06:55:03
Calc: threaded
Comment 20 Kevin Suo 2021-10-22 07:50:15 UTC
Could someone who can reproduce this, prepare a valid gdb backtrace, with debug symbols enabled, following the instructions at:

1. The following build instructions if you can build libreoffice by yourself (it is easy to build, just the build process itself takes some hours:
https://wiki.documentfoundation.org/Development/BuildingOnLinux

You should use -enable-debug in your autogen.input file or pass as an ./autogen.sh build option, to be able to enable debug symbols. See:
https://wiki.documentfoundation.org/Development/How_to_debug#Debugging_options

After the build has finished, run libreoffice once using:
$ ./instdir/program/soffice
then quit, and then run it in debug mode using:
$ make debugrun
then try to reproduce the crash. After it is crashed, you will have a gdbtrace.log file in your build root folder. Attach it to this bug report.

2. If you are not able to build libreoffice, then you can download a debug build version from:
https://dev-builds.libreoffice.org/daily/master/Linux-rpm_deb-x86_64@86-TDF-dbg/current/

then following the instructions in:
https://wiki.documentfoundation.org/Development/How_to_debug#Attaching_to_the_soffice.bin_process
Comment 21 Buovjaga 2021-10-22 07:55:12 UTC
Some Linux distros also provide debug packages: https://wiki.documentfoundation.org/QA/BugReport/Debug_Information#GNU.2FLinux
Comment 22 Julien Nabet 2022-09-17 15:55:44 UTC
Could someone give a try with a recent LO version 7.3.6 or 7.4.1 on a recent Linux distrib?
If you reproduce the crash, please apply what Kevin indicated in https://bugs.documentfoundation.org/show_bug.cgi?id=114314#c20
Comment 23 QA Administrators 2023-03-17 03:26:50 UTC Comment hidden (obsolete)
Comment 24 QA Administrators 2023-04-17 03:20:13 UTC
Dear Chris Piker,

Please read this message in its entirety before proceeding.

Your bug report is being closed as INSUFFICIENTDATA due to inactivity and
a lack of information which is needed in order to accurately
reproduce and confirm the problem. We encourage you to retest
your bug against the latest release. If the issue is still
present in the latest stable release, we need the following
information (please ignore any that you've already provided):

a) Provide details of your system including your operating
   system and the latest version of LibreOffice that you have
   confirmed the bug to be present

b) Provide easy to reproduce steps – the simpler the better

c) Provide any test case(s) which will help us confirm the problem

d) Provide screenshots of the problem if you think it might help

e) Read all comments and provide any requested information

Once all of this is done, please set the bug back to UNCONFIRMED
and we will attempt to reproduce the issue. Please do not:

a) respond via email 

b) update the version field in the bug or any of the other details
   on the top section of our bug tracker

Warm Regards,
QA Team

MassPing-NeedInfo-FollowUp