1
0
mirror of git://git.code.sf.net/p/zsh/code synced 2024-09-28 15:01:21 +02:00

43511: Initialiase alias entry on input stack.

This didn't happen if neither history nor alias expansion was in use.
This commit is contained in:
Peter Stephenson 2018-09-21 16:29:07 +01:00
parent 624219e0e4
commit e76ea18477
2 changed files with 7 additions and 0 deletions

@ -1,3 +1,8 @@
2018-09-21 Peter Stephenson <p.w.stephenson@ntlworld.com>
* 43511: Src/input.c: alias entry on input stack wasn't
initialised if not expanding alias or using history.
2018-09-19 Maximilian Bosch <maximilian@mbosch.me>
* 43502: Completion/X/Command/_setxkbmap: Search XDG_DATA_DIRS

@ -555,6 +555,7 @@ inpush(char *str, int flags, Alias inalias)
if ((instacktop->alias = inalias))
inalias->inuse = 1;
} else {
instacktop->alias = NULL;
/* If we are continuing an alias expansion, record the alias
* expansion in new set of flags (do we need this?)
*/
@ -691,6 +692,7 @@ char *input_hasalias(void)
{
if (!(flags & INP_CONT))
break;
DPUTS(instackptr == instack, "BUG: continuation at bottom of instack");
instackptr--;
if (instackptr->alias)
return instackptr->alias->node.nam;