From: Eduardo Bustamante <dualbus@gmail.com>
To: zsh-workers@zsh.org
Cc: "Eduardo A. Bustamante López" <dualbus@gmail.com>
Subject: Zsh parser segmentation fault in putpromptchar putpromptchar at prompt.c
Date: Mon, 8 May 2017 13:42:46 -0500 [thread overview]
Message-ID: <CAOSMAuv62M+tmz4J+j5zOVTSV6gMiK8RLTu6MAQSO4tcT-qgiw@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 2234 bytes --]
dualbus@debian:~/bash-fuzzing/zsh-parser$ base64 segfault
JHsoJVUpWS0lKHZ9
dualbus@debian:~/bash-fuzzing/zsh-parser$ md5sum segfault
0d79a8c613315f32a453d5aa07a7de65 segfault
dualbus@debian:~/bash-fuzzing/zsh-parser$ cat -v segfault
${(%U)Y-%(v}
(gdb) r -n segfault
Starting program: /home/dualbus/src/zsh/zsh/Src/zsh -n segfault
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Program received signal SIGSEGV, Segmentation fault.
0x00000000004aab3e in putpromptchar (doprint=1, endchar=0,
txtchangep=0x0) at prompt.c:403
403 if (*psvar[(arg ? arg : 1) - 1])
(gdb) bt
#0 0x00000000004aab3e in putpromptchar (doprint=1, endchar=0,
txtchangep=0x0) at prompt.c:403
#1 0x00000000004aa170 in promptexpand (s=0x7ffff7e5b3f8 "%(V", ns=0,
rs=0x0, Rs=0x0, txtchangep=0x0) at prompt.c:215
#2 0x00000000004bd792 in paramsubst (l=0x7fffffffbfa0,
n=0x7ffff7e5b3d8, str=0x7fffffffb950, qt=0, pf_flags=0,
ret_flags=0x7fffffffbf2c) at subst.c:3589
#3 0x00000000004b4fe3 in stringsubst (list=0x7fffffffbfa0,
node=0x7ffff7e5b3d8, pf_flags=0, ret_flags=0x7fffffffbf2c, asssub=0)
at subst.c:247
#4 0x00000000004b4395 in prefork (list=0x7fffffffbfa0, flags=0,
ret_flags=0x7fffffffbf2c) at subst.c:85
#5 0x0000000000440df5 in execcmd_getargs (preargs=0x7ffff7e5b3c0,
args=0x7ffff7e5b380, expand=1) at exec.c:2659
#6 0x000000000043c1eb in execcmd_exec (state=0x7fffffffde40,
eparams=0x7fffffffcd00, input=0, output=0, how=18, last1=2)
at exec.c:2765
#7 0x000000000043b804 in execpline2 (state=0x7fffffffde40, pcode=131,
how=18, input=0, output=0, last1=0) at exec.c:1873
#8 0x0000000000433f6e in execpline (state=0x7fffffffde40,
slcode=3074, how=18, last1=0) at exec.c:1602
#9 0x0000000000432dfe in execlist (state=0x7fffffffde40,
dont_change_job=0, exiting=0) at exec.c:1360
#10 0x000000000043277e in execode (p=0x7ffff7e5b320,
dont_change_job=0, exiting=0, context=0x4d9174 "toplevel") at
exec.c:1141
#11 0x000000000045e366 in loop (toplevel=1, justonce=0) at init.c:208
#12 0x00000000004627d6 in zsh_main (argc=3, argv=0x7fffffffe468) at init.c:1692
#13 0x0000000000411a32 in main (argc=3, argv=0x7fffffffe468) at ./main.c:93
[-- Attachment #2: segfault --]
[-- Type: application/octet-stream, Size: 12 bytes --]
${(%U)Y-%(v}
next reply other threads:[~2017-05-08 18:43 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20170508184346epcas2p364369da57566738a36b888054303eee5@epcas2p3.samsung.com>
2017-05-08 18:42 ` Eduardo Bustamante [this message]
2017-05-09 8:30 ` Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAOSMAuv62M+tmz4J+j5zOVTSV6gMiK8RLTu6MAQSO4tcT-qgiw@mail.gmail.com \
--to=dualbus@gmail.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).