zsh crashes with out of memory error

Solution Verified - Updated -

Issue

  • Tab completion after a subshell command causes ZSH to crash:
$ zsh
$ autoload -U compinit && compinit -u
$ echo $(echo x)<TAB>
zsh: fatal error: out of memory
  • GDB Backtrace:
#0  __GI_exit (status=1) at exit.c:99
#1  0x0000000000453181 in zalloc ()
#2  0x00007ffff0309a54 in do_completion () from /usr/lib64/zsh/5.0.2/zsh/complete.so
#3  0x00007ffff054c3ef in docomplete () from /usr/lib64/zsh/5.0.2/zsh/zle.so
#4  0x00007ffff0548d10 in completecall () from /usr/lib64/zsh/5.0.2/zsh/zle.so
#5  0x00007ffff053a2b6 in execzlefunc () from /usr/lib64/zsh/5.0.2/zsh/zle.so
#6  0x00007ffff053a5b9 in zlecore () from /usr/lib64/zsh/5.0.2/zsh/zle.so
#7  0x00007ffff053b1dd in zleread () from /usr/lib64/zsh/5.0.2/zsh/zle.so
#8  0x00000000004405d2 in zleentry ()
#9  0x00000000004419d6 in ingetc ()
#10 0x000000000043abf6 in ihgetc ()
#11 0x000000000044b91e in zshlex ()
#12 0x0000000000469036 in parse_event ()
#13 0x000000000043dc3e in loop ()
#14 0x0000000000440fce in zsh_main ()
#15 0x00007ffff6ecab15 in __libc_start_main (main=0x40ed00 <main>, argc=1, ubp_av=0x7fffffffdb08, init=<optimized out>, fini=<optimized out>, 
    rtld_fini=<optimized out>, stack_end=0x7fffffffdaf8) at libc-start.c:274
#16 0x000000000040ed31 in _start ()

Environment

  • Red Hat Enterprise Linux 7.2

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.