1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-12-07 06:02:21 +01:00

39507: TMPSUFFIX for =(...)

This commit is contained in:
Barton E. Schaefer 2016-09-29 14:55:49 -07:00
parent e61ed2b80d
commit 736eb433ba
3 changed files with 20 additions and 0 deletions

View file

@ -4421,6 +4421,15 @@ getoutputfile(char *cmd, char **eptr)
if (!s)
child_unblock();
return NULL;
} else {
char *suffix = getsparam("TMPSUFFIX");
if (suffix && *suffix && !strstr(suffix, "/")) {
suffix = dyncat(nam, unmeta(suffix));
if (link(nam, suffix) == 0) {
addfilelist(nam, 0);
nam = ztrdup(suffix);
}
}
}
addfilelist(nam, 0);