[okular] [Bug 396326] New: Crash on right-click over a specific section of the TOC of a specific document

2018-07-08 Thread Luigi Toscano
https://bugs.kde.org/show_bug.cgi?id=396326

Bug ID: 396326
   Summary: Crash on right-click over a specific section of the
TOC of a specific document
   Product: okular
   Version: unspecified
  Platform: Compiled Sources
OS: Linux
Status: UNCONFIRMED
  Keywords: drkonqi
  Severity: crash
  Priority: NOR
 Component: general
  Assignee: okular-devel@kde.org
  Reporter: luigi.tosc...@tiscali.it
  Target Milestone: ---

Application: okular (1.4.70)
 (Compiled from sources)
Qt Version: 5.10.1
Frameworks Version: 5.47.0
Operating System: Linux 4.16.0-2-amd64 x86_64
Distribution: Debian GNU/Linux testing (buster)

-- Information about the crash:
- What I was doing when the application crashed:
Open the following document:
https://education.ti.com/~/media/4FE3911D94A041E28095C140297E1062

Right clicking on any entry related to Appendix B of the Table of Context leads
to the crash whose traceback is attached.
The traceback seems to hint that the page number is not properly discovered.
It is worth noting than a left click on the same entries which cause the crash
do not move the viewport. Clicking other entries of the TOC moves the viewport
to the relevant point as expected.

It was originally reported by another user with compiled packages (Okular
1.4.2, Frameworks 5.43, Qt 5.10.1, poppler 0.63) on VoidLinux.
Reproduced with a self-compiled Okular 1.4.70 (current git master), Frameworks
5.47, Qt 5.10.1, poppler 0.63 (the last two from Debian testing).

The crash can be reproduced every time.

-- 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 0x7f8de7b53840 (LWP 9142))]

Thread 4 (Thread 0x7f8db5c29700 (LWP 9397)):
#0  0x7f8de19075d9 in __GI___poll (fds=0x7f8db000b0d0, nfds=1,
timeout=8697) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x7f8ddcc2a439 in ?? () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x7f8ddcc2a54c in g_main_context_iteration () from
/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x7f8de27f21bb in
QEventDispatcherGlib::processEvents(QFlags) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x7f8de2795b6a in
QEventLoop::exec(QFlags) () from
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#5  0x7f8de25ab7ea in QThread::exec() () from
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#6  0x7f8de25b0b4f in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#7  0x7f8ddf85e5aa in start_thread (arg=0x7f8db5c29700) at
pthread_create.c:463
#8  0x7f8de1911cbf in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:95

Thread 3 (Thread 0x7f8dbd306700 (LWP 9154)):
#0  0x7f8ddf8644ec in futex_wait_cancelable (private=,
expected=0, futex_word=0x55d7990ba700) at
../sysdeps/unix/sysv/linux/futex-internal.h:88
#1  __pthread_cond_wait_common (abstime=0x0, mutex=0x55d7990ba6b0,
cond=0x55d7990ba6d8) at pthread_cond_wait.c:502
#2  __pthread_cond_wait (cond=0x55d7990ba6d8, mutex=0x55d7990ba6b0) at
pthread_cond_wait.c:655
#3  0x7f8dbdf94cdb in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#4  0x7f8dbdf94a07 in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#5  0x7f8ddf85e5aa in start_thread (arg=0x7f8dbd306700) at
pthread_create.c:463
#6  0x7f8de1911cbf in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:95

Thread 2 (Thread 0x7f8dcb74c700 (LWP 9149)):
#0  0x7f8ddcc6fcf0 in g_mutex_unlock () from
/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#1  0x7f8ddcc2a42e in ?? () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x7f8ddcc2a54c in g_main_context_iteration () from
/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x7f8de27f21bb in
QEventDispatcherGlib::processEvents(QFlags) ()
from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x7f8de2795b6a in
QEventLoop::exec(QFlags) () from
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#5  0x7f8de25ab7ea in QThread::exec() () from
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#6  0x7f8de2c15df5 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5DBus.so.5
#7  0x7f8de25b0b4f in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#8  0x7f8ddf85e5aa in start_thread (arg=0x7f8dcb74c700) at
pthread_create.c:463
#9  0x7f8de1911cbf in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:95

Thread 1 (Thread 0x7f8de7b53840 (LWP 9142)):
[KCrash Handler]
#6  0x7f8dc9c48912 in Okular::Page::number() const () from
/opt/kf5/lib/x86_64-linux-gnu/libOkular5Core.so.9
#7  0x7f8dc9f9ff0e in Okular::Part::showMenu(Okular::Page const*, QPoint
const&, QString const&, Okular::DocumentViewport const&) () from
/opt/kf5/lib/x86_64-linux-gnu/plugins/okularpart.so
#8  0x7f8dc9f9fd21 in
Okular::Part::slotShowTOCMenu(Okular::DocumentViewport const&, QPoint const&,
QString const&) () from /opt/kf5/lib/x86_64-linux-gnu/plugins/okularpart.so

D13203: Add Typewriter annotation tool in Okular

2018-07-08 Thread Dileep Sankhla
dileepsankhla updated this revision to Diff 37378.
dileepsankhla added a comment.


  Updated generator/poppler for text color

REPOSITORY
  R223 Okular

CHANGES SINCE LAST UPDATE
  https://phabricator.kde.org/D13203?vs=37290=37378

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D13203

AFFECTED FILES
  autotests/annotationstest.cpp
  autotests/parttest.cpp
  conf/editannottooldialog.cpp
  conf/editannottooldialog.h
  core/annotations.cpp
  core/annotations.h
  generators/poppler/annots.cpp
  ui/annotationpropertiesdialog.cpp
  ui/annotationwidgets.cpp
  ui/annotationwidgets.h
  ui/annotwindow.cpp
  ui/data/CMakeLists.txt
  ui/data/sources/tool-typewriter-okular-colorizable.svgz
  ui/data/tool-typewriter-okular-colorizable.png
  ui/data/tool-typewriter-okular-coloriza...@2x.png
  ui/data/tools.xml
  ui/guiutils.cpp
  ui/pagepainter.cpp
  ui/pageviewannotator.cpp

To: dileepsankhla, tobiasdeiminger
Cc: ltoscano, ngraham, tobiasdeiminger, aacid, okular-devel