linuxmint / linuxmint/xreader

Segmentation fault in ev_hyperlink_get_end_index when opening specific PDF

Open
#700 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
283
Forks
82
PR merge metrics
No merged PRs in 30d

Description

Distribution

Mint 21.3

Package version

4.0.2

Frequency

Always

Bug description

Xreader crashes with a segmentation fault when attempting to open or render a PDF file containing certain hyperlinks. The crash seems to occur during the document indexing/loading phase when processing hyperlinks.

Steps to reproduce
  1. Open a PDF document that contains specific (possibly malformed) hyperlinks.
  2. The application crashes immediately with "Segmentation fault (core dumped)".
Expected behavior

The application should open the document normally, or at least skip/ignore the problematic hyperlink instead of crashing.

Additional information

omek127-bo.pdf

Library involved: libxreaderview.so.3

Crash Log / Stack Trace Snippet:

kernel: xreader[17892]: segfault at 7fe6d012c8f0 ip 00007fc881a02c14 sp 00007ffc5f6e2440 error 4 in libxreaderview.so.3.0.0
systemd-coredump: Process 17892 (xreader) of user 1000 dumped core.

#0  0x00007fc881a02c14 ev_hyperlink_get_end_index (libxreaderview.so.3 + 0x25c14)
#2  0x00007fc8819feaeb ev_job_thread_proxy (libxreaderview.so.3 + 0x21aeb)
#10 0x000055a83fbc1eb7 main (xreader + 0x28eb7)

Additional Context: The crash was narrowed down to the function ev_hyperlink_get_end_index. Removing the hyperlink from the PDF source resolved the crash, confirming that the issue is related to how Xreader handles specific link metadata.

I tried also with the most recent version (4.6.3) which did the same. Subsequently I downgraded it, because the icons did not appear in the update.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the crash with omerk127-bo.pdf and inspect the ev_hyperlink_get_end_index path in libxreaderview.so.3 during document loading or rendering. Compare behavior with the problematic hyperlink removed; done means the supplied PDF opens or renders without a segmentation fault while other hyperlinks continue to work.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.