Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh 5.3.1 crashes on completion
- X-seq: zsh-workers 41103
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx, ChenYao <chenyao@xxxxxxxxxxx>
- Subject: Re: zsh 5.3.1 crashes on completion
- Date: Sat, 13 May 2017 11:23:13 -0700
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=from:message-id:date:in-reply-to:comments:references:to:subject :mime-version; bh=57btJFx5gdON8kQtB3IQN7xT1dqIkL3z+YV5ekSDEL8=; b=IcnyQXyT7PI+aAWKunAc7GM1xcKX1EJjSFEfPHBxyikRquyQPn3b12cGZ69AfxgXBE EKiyKsIjIekUpJXvSNc6lBCnIYQJHl0xaG57k+BPShjflkDl+9QNe9SuF0ouVm6onZ5S lPS5+wVnuOpDM6OzkwGM1Se4k+IssCTH1+559aQbEw4qOVGq5Vrv6FyQusCeoLwRLJev 5JNismwsFJJWrf2fIfoAsDXVOnOU9uPzFku7hnOhCh8UBK/xf9CRxW4ML8c9Owvn4CSX iCGTtwSzU/a+J3bQTNfxnlzPMzP83nRnPmLK383FyRFqMJytUxSZZaXlRqEmf74b2jKn oC9A==
- In-reply-to: <783A691B-B69F-4673-B237-B316CEF26346@remrain.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>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <E2298111-0CDA-429D-B3E8-7B8CE06CD974@remrain.com> <170511141903.ZM13639@torch.brasslantern.com> <20170512161603.GA16688@fujitsu.shahaf.local2> <783A691B-B69F-4673-B237-B316CEF26346@remrain.com>
On May 13, 10:02am, ChenYao wrote:
}
} I find that "setopt histignorealldups" in my zshrc causes the crash.
}
} Reproduce from "zsh -f":
}
} # setopt histignorealldups
} # echo $ZSH_VERSION
} # `r`<press tab here, then crash>
For the record, the interactive parent shell doesn't crash, the shell
that crashes is the one executing the "r" command in the subshell
created by the substitution.
Also for the record it's relatively dangerous to run "r" in backticks
in the first place, because if you do it twice in a row (or even do it
once and then follow that with "r" with no backticks) the shell will
end up in an infinite loop. The failsafe code that keeps "r" from
re-executing itself is defeated by the quotes.
The crash occurs when the history in the subshell is updated to remove
the duplicate of the previous command. Adding new history events is
disabled in subshells so the new event that is supposed to replace the
old one does not exist, and the code wanders off into neverland.
I'm not exactly sure where to fix this, or whether there's something
that can be done about the infinite loop (other than disabling "r"
in subshells entirely).
Messages sorted by:
Reverse Date,
Date,
Thread,
Author