Bug 295993 - Unable to print PDF, okular hangs
Summary: Unable to print PDF, okular hangs
Status: RESOLVED NOT A BUG
Alias: None
Product: okular
Classification: Applications
Component: PDF backend (show other bugs)
Version: 0.10.5
Platform: Debian testing Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-14 11:29 UTC by Nicola Ruggero
Modified: 2012-03-16 11:07 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
PDF that makes okular hang (36.11 KB, application/pdf)
2012-03-14 11:29 UTC, Nicola Ruggero
Details
PDF file printed by lp -d (60.84 KB, application/pdf)
2012-03-14 11:30 UTC, Nicola Ruggero
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nicola Ruggero 2012-03-14 11:29:31 UTC
Created attachment 69610 [details]
PDF that makes okular hang

Hi,
when I try to print PDF okular hangs.
If i try to print it using cups (lp -d <printer> <file.pdf>) it works but the printed sheet contains random chars instead of text.

I tried also to update poppler to 0.18.4 but it still hangs. I use debian squeeze-backports

thanks,
Comment 1 Nicola Ruggero 2012-03-14 11:30:09 UTC
Created attachment 69611 [details]
PDF file printed by lp -d
Comment 2 Albert Astals Cid 2012-03-14 18:10:32 UTC
Does print preview give you anything?
Comment 3 Nicola Ruggero 2012-03-15 07:18:30 UTC
No, sorry. Print preview also hangs.
Comment 4 Albert Astals Cid 2012-03-15 18:52:22 UTC
Does pdftops also have the same problem¿
Comment 5 Nicola Ruggero 2012-03-16 10:00:36 UTC
Hi,
it seems to work correctly.

I tried: "pdftops Ft.Aspiag\ Service_31.12.11.pdf 123.ps"
RC=0

lp -d <printer_name> 123.ps
Printed sheets are ok.
Comment 6 Albert Astals Cid 2012-03-16 10:14:17 UTC
You'll need to provide a gdb of the okular hang, it works fine here.
Comment 7 Albert Astals Cid 2012-03-16 10:15:01 UTC
gdb backtrace i mean
Comment 8 Nicola Ruggero 2012-03-16 10:40:38 UTC
Program received signal SIGINT, Interrupt.
0x00007ffff525157d in connect () at ../sysdeps/unix/syscall-template.S:82
82      ../sysdeps/unix/syscall-template.S: No such file or directory.
        in ../sysdeps/unix/syscall-template.S
(gdb) backtrace
#0  0x00007ffff525157d in connect () at ../sysdeps/unix/syscall-template.S:82
#1  0x00007fffe2fb4f0d in httpAddrConnect () from /usr/lib/libcups.so.2
#2  0x00007fffe2fb3f9d in httpReconnect () from /usr/lib/libcups.so.2
#3  0x00007fffe2fb46a6 in httpConnectEncrypt () from /usr/lib/libcups.so.2
#4  0x00007fffe2fd06af in cupsGetPPD3 () from /usr/lib/libcups.so.2
#5  0x00007fffe2fd0b05 in cupsGetPPD () from /usr/lib/libcups.so.2
#6  0x00007ffff5c0afbf in QCUPSSupport::setCurrentPrinter (this=0x7fffffffc040, index=<optimized out>) at painting/qcups.cpp:190
#7  0x00007ffff5c0b893 in QCUPSSupport::QCUPSSupport (this=0x7fffffffc040) at painting/qcups.cpp:141
#8  0x00007ffff5b6fbed in QPdfBaseEngine::QPdfBaseEngine (this=0xd830b0, dd=<optimized out>, f=<optimized out>) at painting/qpdf.cpp:945
#9  0x00007ffff5b800e6 in QPSPrintEngine::QPSPrintEngine (this=0xd830b0, m=QPrinter::ScreenResolution) at painting/qprintengine_ps.cpp:668
#10 0x00007ffff5b85f2f in QPrinterPrivate::createDefaultEngines (this=0xc08630) at painting/qprinter.cpp:219
#11 0x00007ffff5b861e5 in QPrinter::init (this=0x7fffffffc280, mode=15283944) at painting/qprinter.cpp:659
#12 0x00007ffff5b867c4 in QPrinter::QPrinter (this=0x7fffffffc280, mode=QPrinter::ScreenResolution) at painting/qprinter.cpp:621
#13 0x00007fffed17699f in Okular::Part::slotPrint (this=0x741990) at ../../okular/part.cpp:1910
#14 0x00007fffed18082f in Okular::Part::qt_metacall (this=0x741990, _c=QMetaObject::InvokeMetaMethod, _id=<optimized out>, _a=0x7fffffffc450) at ./part.moc:234
#15 0x00007ffff66622e6 in QMetaObject::activate (sender=0xa24710, m=<optimized out>, local_signal_index=<optimized out>, argv=0xffffffffffffffff) at kernel/qobject.cpp:3295
#16 0x00007ffff59e9132 in QAction::triggered (this=0x17, _t1=false) at .moc/release-shared/moc_qaction.cpp:263
#17 0x00007ffff59eb1ab in QAction::activate (this=0xa24710, event=<optimized out>) at kernel/qaction.cpp:1255
#18 0x00007ffff5e2a751 in QMenuPrivate::activateCausedStack (this=<optimized out>, causedStack=..., action=0xa24710, action_e=QAction::Trigger, self=true) at widgets/qmenu.cpp:1002
#19 0x00007ffff5e302e2 in QMenuPrivate::activateAction (this=0xa52940, action=0xa24710, action_e=QAction::Trigger, self=<optimized out>) at widgets/qmenu.cpp:1094
#20 0x00007ffff738c81e in KMenu::mouseReleaseEvent (this=0xa6b440, e=0xe936e8) at ../../kdeui/widgets/kmenu.cpp:471
#21 0x00007ffff5a45632 in QWidget::event (this=0xa6b440, event=0x7fffffffd220) at kernel/qwidget.cpp:8044
#22 0x00007ffff5e324db in QMenu::event (this=0xa6b440, e=0x7fffffffd220) at widgets/qmenu.cpp:2421
#23 0x00007ffff59ef32c in QApplicationPrivate::notify_helper (this=0x62c2f0, receiver=0xa6b440, e=0x7fffffffd220) at kernel/qapplication.cpp:4302
#24 0x00007ffff59f5fdb in QApplication::notify (this=0x7fffffffdd70, receiver=0xa6b440, e=0x7fffffffd220) at kernel/qapplication.cpp:3867
#25 0x00007ffff72b0796 in KApplication::notify (this=0x7fffffffdd70, receiver=0xa6b440, event=0x7fffffffd220) at ../../kdeui/kernel/kapplication.cpp:302
#26 0x00007ffff664f09c in QCoreApplication::notifyInternal (this=0x7fffffffdd70, receiver=0xa6b440, event=0x7fffffffd220) at kernel/qcoreapplication.cpp:726
#27 0x00007ffff59f51be in sendEvent (event=<optimized out>, receiver=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215
#28 QApplicationPrivate::sendMouseEvent (receiver=0xa6b440, event=0x7fffffffd220, alienWidget=0x0, nativeWidget=0xa6b440, buttonDown=<optimized out>, lastMouseReceiver=<optimized out>, spontaneous=true) at kernel/qapplication.cpp:2967
#29 0x00007ffff5a754fd in QETWidget::translateMouseEvent (this=0xa6b440, event=<optimized out>) at kernel/qapplication_x11.cpp:4314
#30 0x00007ffff5a739dc in QApplication::x11ProcessEvent (this=<optimized out>, event=0x7fffffffd9a0) at kernel/qapplication_x11.cpp:3513
#31 0x00007ffff5a9f5a2 in x11EventSourceDispatch (s=0x630060, callback=<optimized out>, user_data=<optimized out>) at kernel/qguieventdispatcher_glib.cpp:146
#32 0x00007ffff17226f2 in g_main_context_dispatch () from /lib/libglib-2.0.so.0
---Type <return> to continue, or q <return> to quit---
#33 0x00007ffff1726568 in ?? () from /lib/libglib-2.0.so.0
#34 0x00007ffff172671c in g_main_context_iteration () from /lib/libglib-2.0.so.0
#35 0x00007ffff66786b3 in QEventDispatcherGlib::processEvents (this=0x614c40, flags=<optimized out>) at kernel/qeventdispatcher_glib.cpp:412
#36 0x00007ffff5a9f19e in QGuiEventDispatcherGlib::processEvents (this=0x17, flags=<optimized out>) at kernel/qguieventdispatcher_glib.cpp:204
#37 0x00007ffff664d9c2 in QEventLoop::processEvents (this=<optimized out>, flags=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece or DW_OP_bit_piece.
) at kernel/qeventloop.cpp:149
#38 0x00007ffff664dd9c in QEventLoop::exec (this=0x7fffffffdcc0, flags=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece or DW_OP_bit_piece.
) at kernel/qeventloop.cpp:201
#39 0x00007ffff6652a2b in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1003
#40 0x000000000040885c in main (argc=<optimized out>, argv=<optimized out>) at ../../../okular/shell/main.cpp:82
Comment 9 Nicola Ruggero 2012-03-16 10:41:38 UTC
I seems it is unable to get printers details from cups... is it correct?
Comment 10 Nicola Ruggero 2012-03-16 10:49:57 UTC
Fund the root cause:
Setting "Browsing Off" in /etc/cups/cupsd.conf okular doesn't hangs anymore.
It seems that cups hangs while browsing local printers on the local network...

The strange is that also printout is correct and I don't know why. I will try to see if this is related to poppler libs.
Comment 11 Nicola Ruggero 2012-03-16 11:07:02 UTC
(In reply to comment #10)
> 
> The strange is that also printout is correct and I don't know why. I will
> try to see if this is related to poppler libs.

Okular prints correctly, lp -d prints random chars. This means I have to analyze filter chain in cups.
Thanks for help, I am going to close this bug here.