Bug 247497 - print/ghostscript9-agpl: Segmentation fault during extracting text from some pdf files
Summary: print/ghostscript9-agpl: Segmentation fault during extracting text from some ...
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Document Engineering Group (Nobody)
URL:
Keywords: crash, needs-qa
Depends on:
Blocks:
 
Reported: 2020-06-23 11:20 UTC by Kaloyan Taralov
Modified: 2020-06-27 17:34 UTC (History)
2 users (show)

See Also:


Attachments
Problematic pdf caused segfault (192.51 KB, application/pdf)
2020-06-23 11:20 UTC, Kaloyan Taralov
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kaloyan Taralov 2020-06-23 11:20:21 UTC
Created attachment 215880 [details]
Problematic pdf caused segfault

gs -q -sDEVICE=txtwrite -dBATCH -dNOPAUSE -sOutputFile=%stdout 1.pdf
Comment 1 Lewis Cook freebsd_triage 2020-06-23 11:28:03 UTC
Hi, thanks for your report.

Are you using the binary package or building the application from ports? It may be worth attaching the output of `pkg info -i <package>` as-well-as any information you deem to be relevant. Thanks!

^Lewis
Comment 2 Kaloyan Taralov 2020-06-23 11:35:20 UTC
Hi , I've try both scenarion with binary pkg and compiling with ports. Same result. Especially for the attached pdf problem is caused from barcode , it is not graphic but some kind of glyph font. If I edit document and remove barcode object form pdf it is processed normaly.
Comment 3 Kaloyan Taralov 2020-06-24 17:18:28 UTC
* thread #1, name = 'gs', stop reason = signal SIGBUS
  * frame #0: 0x0000000800a712e2 libgs.so.9`gs_heap_free_object(mem=0x0000000802501000, ptr=0x00000008032afaf0, cname="") at gsmalloc.c:345:24
    frame #1: 0x0000000800937a6a libgs.so.9`txtwrite_output_page(dev=0x0000000802d9d068, num_copies=1, flush=1) at gdevtxtw.c:883:13
    frame #2: 0x0000000800a4a139 libgs.so.9`gs_output_page(pgs=0x000000080258ed18, num_copies=1, flush=1) at gsdevice.c:212:17
    frame #3: 0x0000000800bfaf5a libgs.so.9`zoutputpage(i_ctx_p=0x000000080258ea28) at zdevice.c:416:12
    frame #4: 0x0000000800bad9df libgs.so.9`interp(pi_ctx_p=0x00000008025061d0, pref=0x00007fffffffdad8, perror_object=0x00007fffffffde10) at interp.c:1300:28
    frame #5: 0x0000000800bab056 libgs.so.9`gs_call_interp(pi_ctx_p=0x00000008025061d0, pref=0x00007fffffffdd08, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at interp.c:520:12
    frame #6: 0x0000000800baae09 libgs.so.9`gs_interpret(pi_ctx_p=0x00000008025061d0, pref=0x00007fffffffdd08, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at interp.c:477:12
    frame #7: 0x0000000800b99bff libgs.so.9`gs_main_interpret(minst=0x0000000802506130, pref=0x00007fffffffdd08, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at imain.c:253:12
    frame #8: 0x0000000800b99ea2 libgs.so.9`gs_main_run_string_end(minst=0x0000000802506130, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at imain.c:791:12
    frame #9: 0x0000000800b99ca1 libgs.so.9`gs_main_run_string_with_length(minst=0x0000000802506130, str="<362e706466>.runfile", length=20, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at imain.c:735:12
    frame #10: 0x0000000800b98af1 libgs.so.9`gs_main_run_string(minst=0x0000000802506130, str="<362e706466>.runfile", user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at imain.c:716:12
    frame #11: 0x0000000800b9edaa libgs.so.9`run_string(minst=0x0000000802506130, str="<362e706466>.runfile", options=3, user_errors=1, pexit_code=0x00007fffffffde24, perror_object=0x00007fffffffde10) at imainarg.c:1119:12
    frame #12: 0x0000000800b9f01f libgs.so.9`runarg(minst=0x0000000802506130, pre="", arg="6.pdf", post="", options=3, user_errors=1, pexit_code=0x0000000000000000, perror_object=0x0000000000000000) at imainarg.c:1088:12
    frame #13: 0x0000000800b9ebc3 libgs.so.9`argproc(minst=0x0000000802506130, arg="6.pdf") at imainarg.c:1010:16
    frame #14: 0x0000000800b9c1b8 libgs.so.9`gs_main_init_with_args01(minst=0x0000000802506130, argc=6, argv=0x00007fffffffeb58) at imainarg.c:241:24
    frame #15: 0x0000000800b9ec93 libgs.so.9`gs_main_init_with_args(minst=0x0000000802506130, argc=6, argv=0x00007fffffffeb58) at imainarg.c:288:16
    frame #16: 0x0000000800ba1fc5 libgs.so.9`psapi_init_with_args(ctx=0x0000000802506030, argc=6, argv=0x00007fffffffeb58) at psapi.c:272:12
    frame #17: 0x0000000800c47dab libgs.so.9`gsapi_init_with_args(instance=0x0000000802506030, argc=6, argv=0x00007fffffffeb58) at iapi.c:148:12
    frame #18: 0x0000000000201360 gs`main(argc=6, argv=0x00007fffffffeb58) at dxmainc.c:86:16
    frame #19: 0x000000000020110f gs`_start(ap=<unavailable>, cleanup=<unavailable>) at crt1.c:76:7
Comment 4 Li-Wen Hsu freebsd_committer 2020-06-27 17:34:09 UTC
Forward to print/ghostscript9-agpl-base maintainer.