mirror of
https://github.com/zsh-users/zsh
synced 2024-07-21 10:14:19 +00:00
Don't crash if alt-y is typed twice in a row without a prior ctrl-y.
This commit is contained in:
parent
0f080f741c
commit
1495a7e008
|
@ -372,8 +372,10 @@ yankpop(char **args)
|
|||
int cc, kctstart = kct;
|
||||
Cutbuffer buf;
|
||||
|
||||
if (!(lastcmd & ZLE_YANK) || !kring)
|
||||
if (!(lastcmd & ZLE_YANK) || !kring || !kctbuf) {
|
||||
kctbuf = NULL;
|
||||
return 1;
|
||||
}
|
||||
do {
|
||||
/*
|
||||
* This is supposed to make the yankpop loop
|
||||
|
|
Loading…
Reference in a new issue