Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Zsh crashes on `compadd` when using `_history` completer & zstyle `ignored-patterns` is set
- X-seq: zsh-workers 45921
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: Marlon Richert <marlon.richert@xxxxxxxxx>
- Subject: Re: Zsh crashes on `compadd` when using `_history` completer & zstyle `ignored-patterns` is set
- Date: Tue, 26 May 2020 18:48:30 +0000
- Cc: Zsh hackers list <zsh-workers@xxxxxxx>
- In-reply-to: <CAHLkEDtGT89iRnbe+VDbBdMU1LqDY0Z=BCbH9Qqhgv2+XrKJJw@mail.gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAHLkEDtGT89iRnbe+VDbBdMU1LqDY0Z=BCbH9Qqhgv2+XrKJJw@mail.gmail.com>
Marlon Richert wrote on Mon, 25 May 2020 14:02 +0300:
> *Given*
>
> - A .zshrc file containing the following lines:
>
> HISTFILE=${ZDOTDIR:-$HOME}/.zsh_history
> HISTSIZE=2000
> SAVEHIST=1000
> autoload -Uz compinit
> compinit
> zstyle ':completion:*' ignored-patterns ''
>
>
> - A `${ZDOTDIR:-$HOME}/.zsh_history` file that contains >1000 lines of
> history.
>
> *When*
>
> 1. I start a new shell with `zsh -dxv &>! ~/zsh-debug.log`
> 2. I press `^[/` to activate `_history-complete-older` (or anything else
> that uses the `_history` completer).
>
> *Then*
>
> - Zsh crashes with the message `zsh: segmentation fault`.
> - `~/zsh-debug.log` ends in the following lines:
>
I followed these steps as follows:
[[[
$ cd "$(mktemp -d)"
$ tee .zshrc
HISTFILE=${ZDOTDIR:-$HOME}/.zsh_history
HISTSIZE=2000
SAVEHIST=1000
autoload -Uz compinit
compinit
zstyle ':completion:*' ignored-patterns ''
<pressed Ctrl+D>
$ yes | head -1001 > .zsh_history
$ ZDOTDIR=$PWD $builddir/Src/zsh -d
% bindkey -e
% <pressed M-/>
]]]
The terminal beeped and no crash happened.
What's your $ZSH_VERSION and $ZSH_PATCHLEVEL?
Messages sorted by:
Reverse Date,
Date,
Thread,
Author