[poppler] Poppler 0.8.2 released

Pino Toscano pino at kde.org
Fri May 2 04:27:20 PDT 2008


Alle venerdì 02 maggio 2008, James Cloos ha scritto:
> After I recompiled poppler and xpdf-on-poppler with -ggdb I no longer
> get the SEGV from pdftoppm, only from xpdf.  It looks like:

... not really useful, as all the interesting part is stripped.
Attached you find a much better backtrace, that clearly shows the problem.

In AnnotWidget::initialize(), in case there is a global Form object (that 
corresponds to the AcroForm object in the Catalog), it looks for the 
reference of the current (form widget) annotation in the fields of the 
AcroForm. But (at least in the first of the two documents) the Fields entry 
in AcroForm has no entries, and thus a null FormWidget* is returned, but it's 
dereferenced anyway, -> crash.

I attached a very simple patch that checks whether the FormWidget* is valid, 
and the faulty pages of the documents seem to load fine now.
Iñigo, what do you think?

-- 
Pino Toscano
-------------- next part --------------
0x00002b8a95a950ee in FormWidget::getType (this=0x0) at poppler/Form.h:71
71        FormFieldType getType() { return type; }
(gdb) bt
#0  0x00002b8a95a950ee in FormWidget::getType (this=0x0) at poppler/Form.h:71
#1  0x00002b8a95d7f0a4 in AnnotWidget::initialize (this=0xacd930, xrefA=0x7368e0, catalog=0x7221e0, dict=0x667ee0)
    at poppler/Annot.cc:1818
#2  0x00002b8a95d837f3 in AnnotWidget (this=0xacd930, xrefA=0x7368e0, dict=0x667ee0, catalog=0x7221e0, obj=0x7fff152a4a40)
    at poppler/Annot.cc:1791
#3  0x00002b8a95d85662 in Annots::createAnnot (this=0x77e200, xref=0x7368e0, dict=0x667ee0, catalog=0x7221e0, obj=0x7fff152a4a40)
    at poppler/Annot.cc:3898
#4  0x00002b8a95d85a7c in Annots (this=0x77e200, xref=0x7368e0, catalog=0x7221e0, annotsObj=0x7fff152a4b40)
    at poppler/Annot.cc:3837
#5  0x00002b8a95e08046 in Page::displaySlice (this=0x7154a0, out=0x7045e0, hDPI=72, vDPI=72, rotate=0, useMediaBox=0, crop=1, sliceX=-1, sliceY=-1,
    sliceW=-1, sliceH=-1, printing=0, catalog=0x7221e0, abortCheckCbk=0, abortCheckCbkData=0x0, annotDisplayDecideCbk=0, annotDisplayDecideCbkData=0x0)
    at poppler/Page.cc:420
#6  0x00002b8a95e0da0d in PDFDoc::displayPageSlice (this=0x707c40, out=0x7045e0, page=6, hDPI=72, vDPI=72, rotate=0, useMediaBox=0, crop=1, printing=0,
    sliceX=-1, sliceY=-1, sliceW=-1, sliceH=-1, abortCheckCbk=0, abortCheckCbkData=0x0, annotDisplayDecideCbk=0, annotDisplayDecideCbkData=0x0)
    at poppler/PDFDoc.cc:405
#7  0x00002b8a95a8fc91 in Poppler::Page::renderToImage (this=0xae8cb0, xres=72, yres=72, x=-1, y=-1, w=-1, h=-1, rotate=Poppler::Page::Rotate0)
    at qt4/src/poppler-page.cc:196
#8  0x00000000004158b0 in PageView::pageChanged (this=0x697160, page=5) at qt4/demos/pageview.cpp:52
#9  0x000000000041836e in PdfViewer::setPage (this=0x6920a0, page=5) at qt4/demos/viewer.cpp:294
#10 0x000000000040fb87 in DocumentObserver::setPage (this=0x69ba08, page=5) at qt4/demos/documentobserver.cpp:39
#11 0x00000000004145db in NavigationToolBar::slotGoNext (this=0x69b9e0) at qt4/demos/navigationtoolbar.cpp:85
#12 0x000000000041467c in NavigationToolBar::qt_metacall (this=0x69b9e0, _c=QMetaObject::InvokeMetaMethod, _id=2, _a=0x7fff152a5190)
    at /mnt/devel/freedesktop.org/build-poppler/qt4/demos/navigationtoolbar.moc:74
#13 0x00002b8a96ece636 in QMetaObject::activate (sender=0x69fa50, from_signal_index=<value optimized out>, to_signal_index=6, argv=0x667ee0)
    at kernel/qobject.cpp:3010
#14 0x00002b8a97585297 in QAction::triggered (this=0x0, _t1=false) at .moc/release-shared/moc_qaction.cpp:216
#15 0x00002b8a97585aa0 in QAction::activate (this=0x69fa50, event=<value optimized out>) at kernel/qaction.cpp:1119
#16 0x00002b8a97892684 in QAbstractButtonPrivate::click (this=0x69fd40) at widgets/qabstractbutton.cpp:525
#17 0x00002b8a978928f1 in QAbstractButton::mouseReleaseEvent (this=0x69fd10, e=0x7fff152a5a70) at widgets/qabstractbutton.cpp:1112
#18 0x00002b8a97955cca in QToolButton::mouseReleaseEvent (this=0x0, e=0x1ae) at widgets/qtoolbutton.cpp:675
#19 0x00002b8a975da680 in QWidget::event (this=0x69fd10, event=0x7fff152a5a70) at kernel/qwidget.cpp:6920
#20 0x00002b8a97891a20 in QAbstractButton::event (this=0x69fd10, e=0x1ae) at widgets/qabstractbutton.cpp:1074
#21 0x00002b8a97955829 in QToolButton::event (this=0x0, e=0x1ae) at widgets/qtoolbutton.cpp:1105
#22 0x00002b8a9758b86f in QApplicationPrivate::notify_helper (this=0x6258d0, receiver=0x69fd10, e=0x7fff152a5a70) at kernel/qapplication.cpp:3766
#23 0x00002b8a97590649 in QApplication::notify (this=0x7fff152a63f0, receiver=0x69fd10, e=0x7fff152a5a70) at kernel/qapplication.cpp:3495
#24 0x00002b8a96eba519 in QCoreApplication::notifyInternal (this=0x7fff152a63f0, receiver=0x69fd10, event=0x7fff152a5a70)
    at kernel/qcoreapplication.cpp:587
#25 0x00002b8a9758d775 in QApplicationPrivate::sendMouseEvent (receiver=0x69fd10, event=0x7fff152a5a70, alienWidget=<value optimized out>,
    nativeWidget=0x6920a0, buttonDown=<value optimized out>, lastMouseReceiver=@0x2b8a97efc060)
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:218
#26 0x00002b8a975ef89c in QETWidget::translateMouseEvent (this=0x6920a0, event=<value optimized out>) at kernel/qapplication_x11.cpp:4122
#27 0x00002b8a975ee802 in QApplication::x11ProcessEvent (this=0x68, event=0x7fff152a61e0) at kernel/qapplication_x11.cpp:3244
#28 0x00002b8a97614b6f in QEventDispatcherX11::processEvents (this=0x62f500, flags=@0x7fff152a62f0) at kernel/qeventdispatcher_x11.cpp:134
#29 0x00002b8a96eb9995 in QEventLoop::processEvents (this=<value optimized out>, flags=@0x7fff152a6330) at kernel/qeventloop.cpp:149
#30 0x00002b8a96eb9aeb in QEventLoop::exec (this=0x7fff152a6370, flags=@0x7fff152a6380) at kernel/qeventloop.cpp:200
#31 0x00002b8a96ebbb49 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:845
#32 0x0000000000413f2c in main (argc=1, argv=0x7fff152a6508) at qt4/demos/main_viewer.cpp:28
-------------- next part --------------
A non-text attachment was scrubbed...
Name: poppler-annotwidget-crashfix.diff
Type: text/x-diff
Size: 981 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/poppler/attachments/20080502/3933752f/attachment.diff 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freedesktop.org/archives/poppler/attachments/20080502/3933752f/attachment.pgp 


More information about the poppler mailing list