Bug 54435 - segfault when searching text
Summary: segfault when searching text
Status: RESOLVED NOTOURBUG
Alias: None
Product: poppler
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-03 12:37 UTC by Steven Vancoillie
Modified: 2012-09-22 10:55 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
pdf that gives the problem (2.46 MB, application/pdf)
2012-09-03 12:37 UTC, Steven Vancoillie
Details

Description Steven Vancoillie 2012-09-03 12:37:22 UTC
Created attachment 66539 [details]
pdf that gives the problem

When looking at a (specific) pdf file with zathura, searching for text gave a segfault. This is reproducible but seemingly occurs random after searching for a few word. I traced this back to poppler, backtrace from gdb:

Program received signal SIGSEGV, Segmentation fault.
0x00007fffeb6ef217 in TextPage::findText (this=0x960240, s=<optimized out>, len=6, startAtTop=false, stopAtBottom=true, startAtLast=<optimized out>, stopAtLast=false, caseSensitive=false, backward=false, wholeWord=false, xMin=0x7fffffffb390, yMin=0x7fffffffb398, xMax=0x7fffffffb3a0, yMax=0x7fffffffb3a8) at TextOutputDev.cc:3598

3598	    blk = blocks[i];

(gdb) bt
#0  0x00007fffeb6ef217 in TextPage::findText (this=0x960240, s=<optimized out>, len=6, startAtTop=false, stopAtBottom=true, startAtLast=<optimized out>, stopAtLast=false, caseSensitive=false, backward=false, wholeWord=false, xMin=0x7fffffffb390, yMin=0x7fffffffb398, xMax=0x7fffffffb3a0, yMax=0x7fffffffb3a8) at TextOutputDev.cc:3598
#1  0x00007fffeb9f6082 in poppler_page_find_text (page=<optimized out>, text=<optimized out>) at poppler-page.cc:886
#2  0x00007fffebc3b017 in pdf_page_search_text () from /usr/lib/zathura/pdf.so
#3  0x0000000000415c3f in cmd_search ()
...

When I print the address of 'blocks', it gives 0x0, so I guess that's the culprit...

grtz
Steven
Comment 1 Albert Astals Cid 2012-09-09 22:01:39 UTC
Searching works perfectly fine from the glib demo so i'd say there's something wrong in the zhatura code, having a look at the crashes i get it seems that the zathura code is accessing poppler from two different threads (which is not yet supported).

We'd need to speak with someone that can confirm or unconfirm my hyphotesys, so can you please ask the zatuhra developer to come here and answer my question?
Comment 2 Steven Vancoillie 2012-09-21 19:01:54 UTC
I opened an new issue with the zathura developers, asking them to come and answer your question(s). (http://bugs.pwmt.org/issue253)
Comment 3 Steven Vancoillie 2012-09-22 10:55:36 UTC
The zathura developers solved the bug, thanks for your input!


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.