cdesktopenv/src/cmd
Martijn Dekker 07faf38425 Fix 'unset -f' in sub-subshell (re: 13c57e4b)
A bug introduced in the previous commit caused 'unset -f' in a
subshell of a subshell to fail to unset a function created in a
parent subshell. Reproducer:

$ ( f2() { echo WRONG; }; ( unset -f f2; f2 ) )
WRONG

src/cmd/ksh93/bltins/typeset.c: unall():
- Do not nv_search() in sh.fun_base before setting the dummy node
  that marks the function as unset in this subshell. That search
  only reaches the base tree and not any of its subtrees. Setting
  the dummy unconditionally is not harmful; the cost is negligible.

src/cmd/ksh93/tests/subshell.sh:
- Add test for the bug.
2021-04-24 12:41:40 +01:00
..
INIT Lots of man page fixes and some other minor fixes (#284) 2021-04-23 22:02:30 +01:00
builtin Lots of man page fixes and some other minor fixes (#284) 2021-04-23 22:02:30 +01:00
ksh93 Fix 'unset -f' in sub-subshell (re: 13c57e4b) 2021-04-24 12:41:40 +01:00
Mamfile **/Mamfile: add header comment pointing to MAM docs (re: 6cc2f6a0) 2021-01-25 14:38:58 +00:00