Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Seg Fault in paramsubst()
- X-seq: zsh-workers 15716
- From: Felix Rosencrantz <f_rosencrantz@xxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Seg Fault in paramsubst()
- Date: Mon, 27 Aug 2001 23:24:06 -0700 (PDT)
- In-reply-to: <1010824170526.ZM28196@xxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
When using this in my completer I would sometimes get seg faults. Below
is a stack trace from gdb. I think this stack trace would only occur if there
were either no matches or just one. Though it might just happen in one of
those situations.
> local w p h r
> w=${(q)words[CURRENT-1]}
> p=$'\0'$w$'\0'
> h=$'\0'${(pj:\0:)${(z)history[(R)*$w*]}}
> r=( ${${(ps:\1:)h//$~p/$'\1'}%%$'\0'*} )
> compadd -a r
>
-FR
#0 0x80b472e in paramsubst (l=0xbfffbe88, n=0xbfffbe70, str=0xbfffbc58, qt=0,
ssub=0) at subst.c:1836
#1 0x80af2ec in stringsubst (list=0xbfffbe88, node=0xbfffbe70, ssub=0,
asssub=0) at subst.c:130
#2 0x80aec7f in prefork (list=0xbfffbe88, flags=0) at subst.c:74
#3 0x80af82f in multsub (s=0xbfffc108, a=0xbfffc104, isarr=0xbfffc12c,
sep=0x0) at subst.c:282
#4 0x80b216d in paramsubst (l=0xbfffc3f0, n=0xbfffc3e0, str=0xbfffc1b8, qt=0,
ssub=4) at subst.c:1065
#5 0x80af2ec in stringsubst (list=0xbfffc3f0, node=0xbfffc3e0, ssub=4,
asssub=0) at subst.c:130
#6 0x80aec7f in prefork (list=0xbfffc3f0, flags=6) at subst.c:74
#7 0x8065b6e in addvars (state=0xbfffc4d0, pc=0x8139d5c, export=0)
at exec.c:1516
#8 0x8063a5e in execsimple (state=0xbfffc4d0) at exec.c:753
#9 0x8063bc8 in execlist (state=0xbfffc4d0, dont_change_job=1, exiting=0)
at exec.c:806
#10 0x80639c8 in execode (p=0x8139a68, dont_change_job=1, exiting=0)
at exec.c:729
#11 0x806b388 in runshfunc (prog=0x8139a68, wrap=0x0,
name=0x40249b40 "_history_prev_word") at exec.c:3461
#12 0x401cd80f in comp_wrapper (prog=0x8139a68, w=0x0,
name=0x40249b40 "_history_prev_word") at complete.c:1271
__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/
Messages sorted by:
Reverse Date,
Date,
Thread,
Author