vain / pdfPres

[Discontinued] Dual head PDF presenter: Current slide with context + current slide in fullscreen (Linux, BSD).
http://www.uninformativ.de/projects/_discontinued/pdfpres/
17 stars 10 forks source link

pdfPres freezes #42

Open LordProtector opened 12 years ago

LordProtector commented 12 years ago

When I start pdfPres it shows the first slide and a small black window. The program does not react on any inputs. Even the close button does not work. Only killing the process works.

uname -a

Linux delltux 3.2.0-27-generic #43-Ubuntu SMP Fri Jul 6 14:25:57 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

Do you need any additional information?

vain commented 12 years ago

Hi,

I presume you're using Ubuntu 12.04. Which desktop environment? Which graphics card and which driver? Do you use any special 3D effects? Btw, which version of pdfpres are you using?

LordProtector commented 12 years ago

I use 12.04 with KDE 4.8.4. I use Intel HD 3000 and also tested the NVidia card (binary driver) with optirun from bumblebee-project. I tested it with the default KDE compositing but also disabled it. But nothings works.

./pdfpres -v gives me pdfpres version: pdfpres-0.2.3-9-g5e1c734

I updated to pdfpres version: pdfpres-0.2.3-16-g553ba0f with the same result.

The program runs with 100% on one of the cores, so I think there may be some endless loop.

vain commented 12 years ago

Hm, alright.

Does that happen with every PDF file? Could you try the following file?

http://www.uninformativ.de/tmp/10-pages.pdf

I just fixed a bug that lead to a crash of pdfpres. I don't think (!) that's related to your bug but maybe it's better if you give the latest version on master a try.

I guess that's going to be a little hard to debug because I can't reproduce it. You could try to do the following:

  1. Get the latest code of pdfpres ("git pull" or a fresh "git clone"). cd into pdfpres's source directory.
  2. Compile pdfpres using "CFLAGS=-g make clean pdfpres".
  3. Run pdfpres from within gdb (the GNU debugger): "gdb ./pdfpres"
  4. At gdb's prompt (will show up as "(gdb)"), type: "run /path/pdf/file". pdfpres should start as usual. If everything goes well, you should experience that freeze.
  5. While pdfpres is frozen, you can hit "CTRL-C" in your gdb window. That will interrupt pdfpres and you can enter gdb commands again. At that point, enter "bt" to get a backtrace. Copy that output from your terminal and paste it here.

A backtrace looks something like this:

(gdb) bt
#0  0xb7fdd424 in __kernel_vsyscall ()
#1  0xb73008a3 in __poll_nocancel () from /lib/libc.so.6
#2  0xb758615b in g_poll () from /lib/libglib-2.0.so.0
#3  0xb7577a50 in ?? () from /lib/libglib-2.0.so.0
#4  0xb7577f2b in g_main_loop_run () from /lib/libglib-2.0.so.0
#5  0xb7c95dd0 in gtk_main () from /lib/libgtk-x11-2.0.so.0
#6  0x0804ee18 in main (argc=2, argv=0xbffff184) at pdfpres.c:1910
(gdb)

It will show us where pdfpres got stuck.

LordProtector commented 12 years ago

here is the bt of version pdfpres-0.2.3-17-g9ecc24e

I hope it helps

^C
Program received signal SIGINT, Interrupt.
0x00007ffff75467f9 in IA__gtk_widget_has_rc_style (widget=0x77f600) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:6509
6509    /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c: Datei oder Verzeichnis nicht gefunden.
(gdb) bt
#0  0x00007ffff75467f9 in IA__gtk_widget_has_rc_style (widget=0x77f600) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:6509
#1  0x00007ffff754b28e in gtk_widget_reset_rc_style (widget=0x77f600) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:6577
#2  0x00007ffff754bc4c in IA__gtk_widget_realize (widget=0x77f600) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:3534
#3  0x00007ffff754c868 in IA__gtk_widget_set_parent (widget=0x77f600, parent=0x7782b0) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:6434
#4  0x00007ffff73ecdb6 in IA__gtk_frame_set_label_widget (frame=0x7782b0, label_widget=0x77f600)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkframe.c:391
#5  0x0000000000404d9b in updatePortPixbuf (pp=0x7dbb30) at pdfpres.c:300
#6  0x000000000040678e in onResize (widget=0x7762f0, al=0x7fffffffbad0, port=0x7dbb30) at pdfpres.c:1343
#7  0x00007ffff675eca2 in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#8  0x00007ffff676fd71 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#9  0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#10 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#11 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x7762f0, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#12 0x00007ffff73ecafc in gtk_frame_size_allocate (widget=0x7782b0, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkframe.c:665
#13 0x00007ffff675ec1b in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#14 0x00007ffff6770179 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#15 0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#16 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#17 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x7782b0, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#18 0x00007ffff73c4166 in gtk_event_box_size_allocate (widget=0x776380, allocation=0x7fffffffc5b0)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkeventbox.c:545
#19 0x00007ffff675ec1b in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#20 0x00007ffff6770179 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#21 0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#22 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#23 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x776380, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#24 0x00007ffff74b3ee1 in gtk_table_size_allocate_pass2 (table=<optimized out>) at /build/buildd/gtk+2.0-2.24.10/gtk/gtktable.c:1638
#25 gtk_table_size_allocate (widget=0x778210, allocation=<optimized out>) at /build/buildd/gtk+2.0-2.24.10/gtk/gtktable.c:876
#26 0x00007ffff675ec1b in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
---Type <return> to continue, or q <return> to quit---
#27 0x00007ffff6770179 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#28 0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#29 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#30 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x778210, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#31 0x00007ffff7378e14 in gtk_box_size_allocate (widget=0x776650, allocation=0x7fffffffd110) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkbox.c:500
#32 0x00007ffff675ec1b in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#33 0x00007ffff6770179 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#34 0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#35 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#36 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x776650, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#37 0x00007ffff75527ba in gtk_window_size_allocate (widget=0x660360, allocation=0x7fffffffd670)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwindow.c:5011
#38 0x00007ffff675eca2 in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#39 0x00007ffff6770179 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#40 0x00007ffff6778099 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#41 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#42 0x00007ffff754972e in IA__gtk_widget_size_allocate (widget=0x660360, allocation=<optimized out>)
    at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwidget.c:4097
#43 0x00007ffff7553cec in gtk_window_move_resize (window=0x660360) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwindow.c:6420
#44 gtk_window_check_resize (container=0x660360) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkwindow.c:5425
#45 0x00007ffff675eeca in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#46 0x00007ffff6777741 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#47 0x00007ffff6778242 in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#48 0x00007ffff73aca40 in gtk_container_idle_sizer (data=<optimized out>) at /build/buildd/gtk+2.0-2.24.10/gtk/gtkcontainer.c:1377
#49 0x00007ffff705fd56 in gdk_threads_dispatch (data=0x851560) at /build/buildd/gtk+2.0-2.24.10/gdk/gdk.c:512
#50 0x00007ffff61e3d53 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#51 0x00007ffff61e40a0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#52 0x00007ffff61e449a in g_main_loop_run () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#53 0x00007ffff74282f7 in IA__gtk_main () at /build/buildd/gtk+2.0-2.24.10/gtk/gtkmain.c:1329
#54 0x00000000004082a9 in main (argc=2, argv=0x7fffffffdec8) at pdfpres.c:1910
vain commented 12 years ago

Aye, thank you. So pdfpres gets stuck in size allocate signals.

I can reproduce this on Kubuntu 12.04 x86_64 now. It appears the freeze is caused by setting the labels of the GtkFrames in updatePortPixbuf().

I'm looking into it.

vain commented 12 years ago

Should be fixed on master.