From a675d058db7587eaf2f95da3e6d14fdacf01a7b0 Mon Sep 17 00:00:00 2001 From: Marlon Richert Date: Mon, 6 Sep 2021 14:16:18 -0700 Subject: 49378: skip check for collision of aliases and functions when NO_EXEC --- ChangeLog | 3 +++ Src/parse.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 885b7ed91..2a6b68368 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2021-09-06 Bart Schaefer + * Marlon Richert: 49378: Src/parse.c: skip check for collision + of aliases and functions when NO_EXEC + * 49282: set $0 correctly when calling functions from hooks * 49266: fix segfault on metacharacters in long job texts diff --git a/Src/parse.c b/Src/parse.c index be26112a5..10d193ba1 100644 --- a/Src/parse.c +++ b/Src/parse.c @@ -2052,7 +2052,7 @@ par_simple(int *cmplx, int nr) /* Error if preceding assignments */ if (assignments || postassigns) YYERROR(oecused); - if (hasalias && !isset(ALIASFUNCDEF) && argc && + if (isset(EXECOPT) && hasalias && !isset(ALIASFUNCDEF) && argc && hasalias != input_hasalias()) { zwarn("defining function based on alias `%s'", hasalias); YYERROR(oecused); -- cgit 1.4.1