Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

The pattern containing NUL.



zsh-3.1.6-test-1 dumps core as following on NetBSD 1.4.

Z(2):akr@localhost% Src/zsh -f
localhost% print $OSTYPE 
netbsd1.4
localhost% print $ZSH_VERSION 
3.1.6-test-1
localhost% tmp=a
localhost% print "${line#$'\0'}"
zsh: segmentation fault (core dumped)  Src/zsh -f
Z(2):akr@localhost% 

The backtrace was follows.

Z(2):akr@localhost% gdb Src/zsh zsh.core
GNU gdb 4.17
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386--netbsd"...
Core was generated by `zsh'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/libexec/ld.so...done.
Reading symbols from /usr/lib/libtermcap.so.0.0...done.
Reading symbols from /usr/lib/libc.so.12.40...done.
#0  0x400ea273 in strcpy ()
(gdb) where
#0  0x400ea273 in strcpy ()
#1  0xc1ab5 in ?? ()
#2  0x46797 in paramsubst (l=0xc1a3c, n=0xc1a68, str=0xefbfd22c, qt=1, ssub=0)
    at subst.c:1679
#3  0x41df9 in stringsubst (list=0xc1a3c, node=0xc1a68, ssub=0) at subst.c:122
#4  0x41b63 in prefork (list=0xc1a3c, flags=0) at subst.c:71
#5  0x10509 in execcmd (cmd=0xc18cc, input=0, output=0, how=2, last1=2)
    at exec.c:1505
#6  0xf142 in execpline2 (pline=0xc1a1c, how=2, input=0, output=0, last1=0)
    at exec.c:1054
#7  0xe83b in execpline (l=0xc18b8, how=2, last1=0) at exec.c:869
#8  0xe403 in execlist (list=0xc1a2c, dont_change_job=0, exiting=0)
    at exec.c:738
#9  0x24203 in loop (toplevel=1, justonce=0) at init.c:143
#10 0x19f9 in main (argc=2, argv=0xefbfd4d8) at ./main.c:89
(gdb) 
-- 
Tanaka Akira



Messages sorted by: Reverse Date, Date, Thread, Author