ahrm / sioyek

Sioyek is a PDF viewer with a focus on textbooks and research papers
https://sioyek.info/
GNU General Public License v3.0
6.75k stars 219 forks source link

Hangs and exit when navigating in TOC #1069

Closed unifreak closed 2 months ago

unifreak commented 2 months ago

I'm on archlinux with kernel 6.8.7, using sioyek 2.0.0 from the aur repo.

The problem is: with some pdf files, when navigating in their TOC, sioyek will hang there and output several warnings "warning: found duplicate fz_icc_link in the store" twice then be killed. The full log is here:

...
Creating shared memory block...
Shared memory created: this is the primary application.
Starting IPC server...
IPC server started.
warning: found duplicate fz_icc_link in the store
warning: found duplicate fz_icc_link in the store
Killed

I tried to run a strace all failed syscall, here is what I got after I enter TOC and tried to select an entry for jumping:

ioctl(17, DRM_IOCTL_SYNCOBJ_WAIT, 0x7ffc40636420) = -1 ETIME (Timer expired)
...
futex(0x625b5c5ea848, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
warning: found duplicate fz_icc_link in the store
warning: found duplicate fz_icc_link in the store
futex(0x625b5c7cf250, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
ioctl(17, DRM_IOCTL_SYNCOBJ_WAIT, 0x7ffc406367a0) = -1 ETIME (Timer expired)
futex(0x625b5c7cf250, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
ioctl(17, DRM_IOCTL_SYNCOBJ_WAIT, 0x7ffc406367a0) = -1 ETIME (Timer expired)
futex(0x625b5c7cf250, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
futex(0x72be123f6ac0, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
...
...
ioctl(17, DRM_IOCTL_SYNCOBJ_WAIT, 0x7ffc40635c20) = -1 ETIME (Timer expired)
ioctl(17, DRM_IOCTL_SYNCOBJ_WAIT, 0x7ffc40635c20) = -1 ETIME (Timer expired)
futex(0x625b5c7cf250, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
futex(0x625b5c7cf250, FUTEX_WAIT_PRIVATE, 2, NULL) = -1 EAGAIN (Resource temporarily unavailable)
...
ioctl(17, DRM_IOCTL_I915_GEM_SET_DOMAIN, 0x7ffc40635974) = -1 ENOMEM (Cannot allocate memory)
+++ killed by SIGKILL +++
Killed

Also, I'm sure some older version doesn't have this issue even with the same .pdf files. I myself is not a C developer and cannot make much sense out this. Hope those logs helps for debugging the issue.

Love sioyek! Thanks in advance!

ahrm commented 2 months ago

I think this is a well-known issue with the aur package due to mismatched mupdf versions. See this issue for more information: https://github.com/ahrm/sioyek/issues/733.

unifreak commented 2 months ago

Oh, I forget to search the closed issue. Thanks! I'll follow that issue and see if I can work around this.