Bug 302232 - Unable to print attached PDF file
Summary: Unable to print attached PDF file
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: PDF backend (show other bugs)
Version: 0.14.3
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-20 12:24 UTC by karaluh
Modified: 2012-11-08 08:24 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Test case (602.01 KB, application/zip)
2012-06-20 12:26 UTC, karaluh
Details
New crash information added by DrKonqi (11.76 KB, text/plain)
2012-11-04 15:05 UTC, Bernd Oliver Sünderhauf
Details

Note You need to log in before you can comment on or make changes to this bug.
Description karaluh 2012-06-20 12:24:31 UTC
As in summary, try to print attached PDF to pdf.

Reproducible: Always
Comment 1 karaluh 2012-06-20 12:26:11 UTC
Created attachment 71982 [details]
Test case
Comment 2 Dario Cambié 2012-09-29 19:33:04 UTC
Reproducible here (kde  from GIT trunk).

Output in console:
(lots of)
okular(880) PDFGeneratorPopplerDebugFunction: [Poppler] "Error (1050250): Missing 'endstream' or incorrect stream length"

and a dozen og
GPL Ghostscript 9.05: Error: Font Renderer Plugin ( FreeType ) return code = -1

The second seems to be linked to an upstream bug in libfreetype version 2.4.8 / 2.4.9 [1]

If "Print preview" is used then okular crashes when closed. Follows backtrace:
Application: Okular (okular), signal: Segmentation fault
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0x7fa0f5c04780 (LWP 880))]

Thread 2 (Thread 0x7fa0dfaa2700 (LWP 891)):
#0  0x00007fa0d67d0840 in ?? () from /usr/lib/libgs.so.9
#1  0x00007fa0d67cff0f in gs_gc_reclaim () from /usr/lib/libgs.so.9
#2  0x00007fa0d683ba98 in ?? () from /usr/lib/libgs.so.9
#3  0x00007fa0d679eded in ?? () from /usr/lib/libgs.so.9
#4  0x00007fa0d679abac in interp_reclaim () from /usr/lib/libgs.so.9
#5  0x00007fa0d679c945 in gs_interpret () from /usr/lib/libgs.so.9
#6  0x00007fa0d67920c7 in gs_main_run_string_continue () from /usr/lib/libgs.so.9
#7  0x00007fa0d71ceb72 in spectre_gs_process () from /usr/lib/libspectre.so.1
#8  0x00007fa0d71cef3e in spectre_gs_send_page () from /usr/lib/libspectre.so.1
#9  0x00007fa0d71cf9f6 in spectre_device_render () from /usr/lib/libspectre.so.1
#10 0x00007fa0d71cfe0a in spectre_page_render () from /usr/lib/libspectre.so.1
#11 0x00007fa0d73eb81b in GSRendererThread::run (this=0x1c22f10) at /home/kde/source/kde/kdegraphics/okular/generators/spectre/rendererthread.cpp:71
#12 0x00007fa0f3283b32 in QThreadPrivate::start (arg=0x1c22f10) at /home/kde/source/qt/src/corelib/thread/qthread_unix.cpp:337
#13 0x00007fa0f094ce9a in start_thread (arg=0x7fa0dfaa2700) at pthread_create.c:308
#14 0x00007fa0f297739d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#15 0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7fa0f5c04780 (LWP 880)):
[KCrash Handler]
#6  0x00007fa0f3e98c0c in QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::data (this=0x8) at ../../include/QtCore/../../../../qt/src/corelib/tools/qscopedpointer.h:135
#7  0x00007fa0f3ea92cd in qGetPtrHelper<QScopedPointer<QObjectData> > (p=...) at ../../include/QtCore/../../../../qt/src/corelib/global/qglobal.h:2455
#8  0x00007fa0f3ea9e42 in QWidget::d_func (this=0x0) at ../../include/QtGui/../../../../qt/src/gui/kernel/qwidget.h:150
#9  0x00007fa0f3ef9d94 in QWidget::~QWidget (this=0x7fffa6451430, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:1591
#10 0x00007fa0f3efa2c6 in QWidget::~QWidget (this=0x7fffa6451430, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:1701
#11 0x00007fa0f33d34fe in QObjectPrivate::deleteChildren (this=0x1591150) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:1908
#12 0x00007fa0f3efa081 in QWidget::~QWidget (this=0x1570100, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:1677
#13 0x00007fa0e5ddcea9 in Sidebar::~Sidebar (this=0x1570100, __in_chrg=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/ui/sidebar.cpp:484
#14 0x00007fa0f57f1a43 in KParts::Part::~Part (this=0x14cb5a0, __vtt_parm=0x7fa0e6011b38, __in_chrg=<optimized out>) at /home/kde/source/kde/kdelibs/kparts/part.cpp:209
#15 0x00007fa0e5d6d146 in Okular::Part::~Part (this=0x14cb5a0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:807
#16 0x00007fa0e5d6d1c9 in Okular::Part::~Part (this=0x14cb5a0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:840
#17 0x00007fa0f33d34fe in QObjectPrivate::deleteChildren (this=0x147b200) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:1908
#18 0x00007fa0f3efa081 in QWidget::~QWidget (this=0x147b090, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:1677
#19 0x00007fa0f43ff7e6 in QMainWindow::~QMainWindow (this=0x147b090, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/widgets/qmainwindow.cpp:388
#20 0x00007fa0f4f885d5 in KMainWindow::~KMainWindow (this=0x147b090, __in_chrg=<optimized out>) at /home/kde/source/kde/kdelibs/kdeui/widgets/kmainwindow.cpp:467
#21 0x0000000000409a22 in Shell::~Shell (this=0x147b090, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/shell/shell.cpp:132
#22 0x0000000000409a89 in Shell::~Shell (this=0x147b090, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/shell/shell.cpp:142
#23 0x00007fa0f33d8da6 in qDeleteInEventHandler (o=0x147b090) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:4277
#24 0x00007fa0f33d2194 in QObject::event (this=0x147b090, e=0x1c1c9d0) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:1176
#25 0x00007fa0f3f0d398 in QWidget::event (this=0x147b090, event=0x1c1c9d0) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:8830
#26 0x00007fa0f440199c in QMainWindow::event (this=0x147b090, event=0x1c1c9d0) at /home/kde/source/qt/src/gui/widgets/qmainwindow.cpp:1478
#27 0x00007fa0f4fc6c58 in KXmlGuiWindow::event (this=0x147b090, ev=0x1c1c9d0) at /home/kde/source/kde/kdelibs/kdeui/xmlgui/kxmlguiwindow.cpp:126
#28 0x00007fa0f3ea70d6 in QApplicationPrivate::notify_helper (this=0x13110a0, receiver=0x147b090, e=0x1c1c9d0) at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:4557
#29 0x00007fa0f3ea6dd8 in QApplication::notify (this=0x7fffa6453350, receiver=0x147b090, e=0x1c1c9d0) at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:4522
#30 0x00007fa0f4eca076 in KApplication::notify (this=0x7fffa6453350, receiver=0x147b090, event=0x1c1c9d0) at /home/kde/source/kde/kdelibs/kdeui/kernel/kapplication.cpp:311
#31 0x00007fa0f33b90aa in QCoreApplication::notifyInternal (this=0x7fffa6453350, receiver=0x147b090, event=0x1c1c9d0) at /home/kde/source/qt/src/corelib/kernel/qcoreapplication.cpp:915
#32 0x00007fa0f3e97f81 in QCoreApplication::sendEvent (receiver=0x147b090, event=0x1c1c9d0) at ../../include/QtCore/../../../../qt/src/corelib/kernel/qcoreapplication.h:231
#33 0x00007fa0f33ba0be in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0x12eb670) at /home/kde/source/qt/src/corelib/kernel/qcoreapplication.cpp:1539
#34 0x00007fa0f33b9cdf in QCoreApplication::sendPostedEvents (receiver=0x0, event_type=0) at /home/kde/source/qt/src/corelib/kernel/qcoreapplication.cpp:1432
#35 0x00007fa0f3f73bc9 in QCoreApplication::sendPostedEvents () at ../../include/QtCore/../../../../qt/src/corelib/kernel/qcoreapplication.h:236
#36 0x00007fa0f33f4994 in postEventSourceDispatch (s=0x13119b0) at /home/kde/source/qt/src/corelib/kernel/qeventdispatcher_glib.cpp:279
#37 0x00007fa0ef428d53 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#38 0x00007fa0ef4290a0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#39 0x00007fa0ef429164 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#40 0x00007fa0f33f5243 in QEventDispatcherGlib::processEvents (this=0x12ecb30, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventdispatcher_glib.cpp:424
#41 0x00007fa0f3f7ff1c in QGuiEventDispatcherGlib::processEvents (this=0x12ecb30, flags=...) at /home/kde/source/qt/src/gui/kernel/qguieventdispatcher_glib.cpp:204
#42 0x00007fa0f33b65e4 in QEventLoop::processEvents (this=0x7fffa6451010, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventloop.cpp:149
#43 0x00007fa0f33b676e in QEventLoop::exec (this=0x7fffa6451010, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventloop.cpp:204
#44 0x00007fa0e5aac342 in Okular::Document::closeDocument (this=0x1bedaa0) at /home/kde/source/kde/kdegraphics/okular/core/document.cpp:1865
#45 0x00007fa0e5d6cb39 in closeUrl (this=0x1c1c570, promptToSave=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:1422
#46 Okular::Part::closeUrl (this=0x1c1c570, promptToSave=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:1369
#47 0x00007fa0e5d6d16a in Okular::Part::~Part (this=0x1c1c570, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:813
#48 0x00007fa0e5d6d1c9 in Okular::Part::~Part (this=0x1c1c570, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:840
#49 0x00007fa0f33d34fe in QObjectPrivate::deleteChildren (this=0x1c21ad0) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:1908
#50 0x00007fa0f3efa081 in QWidget::~QWidget (this=0x7fffa6451430, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:1677
#51 0x00007fa0f44d8ffb in QDialog::~QDialog (this=0x7fffa6451430, __in_chrg=<optimized out>) at /home/kde/source/qt/src/gui/dialogs/qdialog.cpp:318
#52 0x00007fa0e5d9081a in Okular::FilePrinterPreview::~FilePrinterPreview (this=0x7fffa6451430, __in_chrg=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/ui/fileprinterpreview.cpp:137
#53 0x00007fa0e5d61e24 in Okular::Part::slotPrintPreview (this=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/part.cpp:2205
#54 0x00007fa0e5d6de8a in qt_static_metacall (_a=<optimized out>, _id=<optimized out>, _o=<optimized out>, _c=<optimized out>) at /home/kde/source/build/kde/kdegraphics/okular/part.moc:183
#55 Okular::Part::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>) at /home/kde/source/build/kde/kdegraphics/okular/part.moc:161
#56 0x00007fa0f33d75a0 in QMetaObject::activate (sender=0x17457a0, m=0x7fa0f4c248e0, local_signal_index=1, argv=0x7fffa6451660) at /home/kde/source/qt/src/corelib/kernel/qobject.cpp:3547
#57 0x00007fa0f3e979c8 in QAction::triggered (this=0x17457a0, _t1=false) at .moc/debug-shared/moc_qaction.cpp:277
#58 0x00007fa0f3e96c88 in QAction::activate (this=0x17457a0, event=QAction::Trigger) at /home/kde/source/qt/src/gui/kernel/qaction.cpp:1257
#59 0x00007fa0f442f76a in QMenuPrivate::activateCausedStack (this=0x17b8bd0, causedStack=..., action=0x17457a0, action_e=QAction::Trigger, self=true) at /home/kde/source/qt/src/gui/widgets/qmenu.cpp:1028
#60 0x00007fa0f442fc1e in QMenuPrivate::activateAction (this=0x17b8bd0, action=0x17457a0, action_e=QAction::Trigger, self=true) at /home/kde/source/qt/src/gui/widgets/qmenu.cpp:1120
#61 0x00007fa0f443433e in QMenu::mouseReleaseEvent (this=0x17aab00, e=0x7fffa6452450) at /home/kde/source/qt/src/gui/widgets/qmenu.cpp:2360
#62 0x00007fa0f4f8b600 in KMenu::mouseReleaseEvent (this=0x17aab00, e=0x7fffa6452450) at /home/kde/source/kde/kdelibs/kdeui/widgets/kmenu.cpp:464
#63 0x00007fa0f3f0bd65 in QWidget::event (this=0x17aab00, event=0x7fffa6452450) at /home/kde/source/qt/src/gui/kernel/qwidget.cpp:8371
#64 0x00007fa0f44349f8 in QMenu::event (this=0x17aab00, e=0x7fffa6452450) at /home/kde/source/qt/src/gui/widgets/qmenu.cpp:2469
#65 0x00007fa0f3ea70d6 in QApplicationPrivate::notify_helper (this=0x13110a0, receiver=0x17aab00, e=0x7fffa6452450) at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:4557
#66 0x00007fa0f3ea505b in QApplication::notify (this=0x7fffa6453350, receiver=0x17aab00, e=0x7fffa6452450) at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:4100
#67 0x00007fa0f4eca076 in KApplication::notify (this=0x7fffa6453350, receiver=0x17aab00, event=0x7fffa6452450) at /home/kde/source/kde/kdelibs/kdeui/kernel/kapplication.cpp:311
#68 0x00007fa0f33b90aa in QCoreApplication::notifyInternal (this=0x7fffa6453350, receiver=0x17aab00, event=0x7fffa6452450) at /home/kde/source/qt/src/corelib/kernel/qcoreapplication.cpp:915
#69 0x00007fa0f3ea9889 in QCoreApplication::sendSpontaneousEvent (receiver=0x17aab00, event=0x7fffa6452450) at ../../include/QtCore/../../../../qt/src/corelib/kernel/qcoreapplication.h:234
#70 0x00007fa0f3ea3687 in QApplicationPrivate::sendMouseEvent (receiver=0x17aab00, event=0x7fffa6452450, alienWidget=0x0, nativeWidget=0x17aab00, buttonDown=0x7fa0f4c70bf8, lastMouseReceiver=..., spontaneous=true) at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:3166
#71 0x00007fa0f3f47678 in QETWidget::translateMouseEvent (this=0x17aab00, event=0x7fffa6452f50) at /home/kde/source/qt/src/gui/kernel/qapplication_x11.cpp:4441
#72 0x00007fa0f3f440e6 in QApplication::x11ProcessEvent (this=0x7fffa6453350, event=0x7fffa6452f50) at /home/kde/source/qt/src/gui/kernel/qapplication_x11.cpp:3508
#73 0x00007fa0f3f7fb62 in x11EventSourceDispatch (s=0x13114f0, callback=0, user_data=0x0) at /home/kde/source/qt/src/gui/kernel/qguieventdispatcher_glib.cpp:146
#74 0x00007fa0ef428d53 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#75 0x00007fa0ef4290a0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#76 0x00007fa0ef429164 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#77 0x00007fa0f33f5243 in QEventDispatcherGlib::processEvents (this=0x12ecb30, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventdispatcher_glib.cpp:424
#78 0x00007fa0f3f7ff1c in QGuiEventDispatcherGlib::processEvents (this=0x12ecb30, flags=...) at /home/kde/source/qt/src/gui/kernel/qguieventdispatcher_glib.cpp:204
#79 0x00007fa0f33b65e4 in QEventLoop::processEvents (this=0x7fffa64532b0, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventloop.cpp:149
#80 0x00007fa0f33b676e in QEventLoop::exec (this=0x7fffa64532b0, flags=...) at /home/kde/source/qt/src/corelib/kernel/qeventloop.cpp:204
#81 0x00007fa0f33b972a in QCoreApplication::exec () at /home/kde/source/qt/src/corelib/kernel/qcoreapplication.cpp:1187
#82 0x00007fa0f3ea42de in QApplication::exec () at /home/kde/source/qt/src/gui/kernel/qapplication.cpp:3818
#83 0x0000000000407f06 in main (argc=<optimized out>, argv=<optimized out>) at /home/kde/source/kde/kdegraphics/okular/shell/main.cpp:94


[1]https://bbs.archlinux.org/viewtopic.php?id=137638
Comment 3 Bernd Oliver Sünderhauf 2012-11-04 15:05:27 UTC
Created attachment 74999 [details]
New crash information added by DrKonqi

okular (0.15.2) on KDE Platform 4.9.2 using Qt 4.8.3

The bug is mostly still reproducible with ghostscript 9.06, libfreetype 2.4.10, libspectre 0.2.7 and libpoppler 0.20.4:

1) The poppler bugs seem to be gone.

2) However, upon preview, Okular emits a couple of these:
  GPL Ghostscript 9.06: Error: Font Renderer Plugin ( FreeType ) return code = -1
so the libfreetype bug doesn't seem to be fully fixed.

3) And when closing, Okular crashes with the following output:

-- Backtrace (Reduced):
#5  QWidget::~QWidget (this=0x7fff27e95e60, __in_chrg=<optimized out>) at kernel/qwidget.cpp:1595
#6  0x00007f9e45068f79 in QWidget::~QWidget (this=0x7fff27e95e60, __in_chrg=<optimized out>) at kernel/qwidget.cpp:1701
#7  0x00007f9e4464f182 in QObjectPrivate::deleteChildren (this=0xbe2870) at kernel/qobject.cpp:1908
#8  0x00007f9e45068c24 in QWidget::~QWidget (this=0xbc69b0, __in_chrg=<optimized out>) at kernel/qwidget.cpp:1677
#9  0x00007f9e35429b29 in Sidebar::~Sidebar (this=0xbc69b0, __in_chrg=<optimized out>) at ../ui/sidebar.cpp:484
Comment 4 Albert Astals Cid 2012-11-05 18:46:57 UTC
Are you guys actually printing the file? Because some of you complain about print preview but the subject of the bug says "Unable to print" not "Unable to print preview" or "Crash while print previewing"
Comment 5 karaluh 2012-11-06 07:28:44 UTC
(In reply to comment #4)
> Are you guys actually printing the file? Because some of you complain about
> print preview but the subject of the bug says "Unable to print" not "Unable
> to print preview" or "Crash while print previewing"

It looks like the print issue is fixed, I am able to print the file now, however: the barcode is not printed correctly and  print preview doesn't work and crashes Okular on exit. Would you like me to report those separately?
Comment 6 Albert Astals Cid 2012-11-07 18:40:31 UTC
Yes please open two separate issues.

Thanks :-)
Comment 7 karaluh 2012-11-08 08:24:40 UTC
(In reply to comment #6)
> Yes please open two separate issues.

The barcode bug:
https://bugs.kde.org/show_bug.cgi?id=309729

The print preview crash:
https://bugs.kde.org/show_bug.cgi?id=309734

which is propably a duplicate of:
https://bugs.kde.org/show_bug.cgi?id=270602

Also I would like to point out, that the current Okular version is 0.15.3 and the highest version available on the bugtracker is 0.15.2