zsh-workers
 help / color / mirror / code / Atom feed
* zsh crash on assignment to $options
@ 2009-01-08 11:39 Andrey Borzenkov
  2009-01-08 12:09 ` Richard Hartmann
  2009-01-08 13:04 ` Peter Stephenson
  0 siblings, 2 replies; 4+ messages in thread
From: Andrey Borzenkov @ 2009-01-08 11:39 UTC (permalink / raw)
  To: zsh-workers

[-- Attachment #1: Type: text/plain, Size: 1530 bytes --]

I got this on after

typeset -A __opts
__opts=${(kv)options}
echo ${options[shwordsplit]}
emulate -R sh
echo ${options[shwordsplit]}
options=$__opts

Stack trace:

(gdb) bt
#0  0x08098427 in setstrvalue (v=0xbfbf1fbc,
    val=0x9028050 "autolist on printexitvalue off kshzerosubscript off 
histreduceblanks off chaselinks off extendedglob off histnostore off 
automenu on globcomplete off unset on listpacked off promptsubst off 
shwordspli"...)
    at params.c:2273
#1  0x0809cf1a in assignsparam (s=0xb80b82cb "",
    val=0x9028050 "autolist on printexitvalue off kshzerosubscript off 
histreduceblanks off chaselinks off extendedglob off histnostore off 
automenu on globcomplete off unset on listpacked off promptsubst off 
shwordspli"...,
    flags=<value optimized out>) at params.c:2617
#2  0x08065c26 in addvars (state=0xbfbf211c, pc=<value optimized out>,
    addflags=<value optimized out>) at exec.c:2112
#3  0x08065e7b in execsimple (state=0xbfbf211c) at exec.c:1002
#4  0x0806c426 in execlist (state=0xbfbf211c, dont_change_job=0, 
exiting=0)
    at exec.c:1112
#5  0x0806cb1e in execode (p=0xb80b8280, dont_change_job=0, exiting=0)
    at exec.c:975
#6  0x0807e08c in loop (toplevel=1, justonce=0) at init.c:181
#7  0x0807f726 in zsh_main (argc=2, argv=0xbfbf2224) at init.c:1406
#8  0x08052a8f in main (argc=0, argv=0x9025050) at ./main.c:93


Using ${(kv)__opts[*]} works (and above is likely an error) still shell 
probably should not react that badly to simple user error.

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-01-08 15:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-08 11:39 zsh crash on assignment to $options Andrey Borzenkov
2009-01-08 12:09 ` Richard Hartmann
2009-01-08 13:04 ` Peter Stephenson
2009-01-08 15:50   ` Richard Hartmann

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).