1
0
Fork 0
mirror of git://git.code.sf.net/p/cdesktopenv/code synced 2025-03-09 15:50:02 +00:00
cde/src/cmd/ksh93/sh
Martijn Dekker 17f81ebedb Load 'r' and 'history' default aliases on interactive only
These two default aliases are useful on interactive shells. In
scripts, they interfere with possible function or command names.

As of this commit, these final two default aliases are only loaded
for interactive shells, leaving zero default aliases for scripts.
This completes the project to get rid of misguided default aliases.

src/cmd/ksh93/include/shtable.h,
src/cmd/ksh93/data/aliases.c:
src/cmd/ksh93/sh/init.c:
- Add empty alias table shtab_noaliases[] for scripts.
- Rename inittree() to sh_inittree() and make it external.
- nv_init(), sh_reinit(): Initialise empty alias tree for scripts.

src/cmd/ksh93/sh/main.c: sh_main():
- If interactive, reinitialise alias tree for interactive shells.

src/cmd/ksh93/tests/alias.sh:
- To test default alias removal, launch shell with -i.
2020-07-16 06:44:05 +01:00
..
args.c Fix process substitution combined with redirection (#40) 2020-06-23 23:02:16 +01:00
arith.c silence macro redefinition warnings (re: 7003aba4) 2020-06-16 04:51:21 +02:00
array.c Fix crashes caused by 'typeset -RF' (#47) 2020-06-28 23:30:27 +01:00
bash.c Fix 47 typos in user-facing help and error messages 2020-06-12 01:45:12 +02:00
defs.c Fix 'test'/'[' exit status >1 on error in arithmetic expression 2020-06-12 01:45:15 +02:00
deparse.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
env.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
expand.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
fault.c Fix a fork bomb when vi is run from a script and sent Ctrl-Z (#73) 2020-07-13 19:10:23 +01:00
fcin.c Fix parsing of multibyte characters 2020-06-12 01:45:17 +02:00
init.c Load 'r' and 'history' default aliases on interactive only 2020-07-16 06:44:05 +01:00
io.c Fix possible crash due to failure to update shell FD state 2020-07-10 20:04:31 +01:00
jobs.c Restore 'set -b'/'set -o notify' functionality (#74) 2020-07-14 22:00:28 +01:00
lex.c Fix ERE repetition expressions in [[ ... =~ ERE{x,y} ]] (#54) 2020-07-02 18:40:15 +01:00
macro.c POSIX compliance fix: apply 'set -u' to $! 2020-06-12 01:45:17 +02:00
main.c Load 'r' and 'history' default aliases on interactive only 2020-07-16 06:44:05 +01:00
name.c Fix memory leak on unset of associative array (#64) 2020-07-09 01:09:40 +01:00
nvdisc.c Fix crashes caused by 'typeset -RF' (#47) 2020-06-28 23:30:27 +01:00
nvtree.c Fix memory corruption when a compound variable is unset (#49) 2020-06-29 18:08:28 +01:00
nvtype.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
parse.c Convert default typeset aliases to regular builtins 2020-07-15 20:54:06 +01:00
path.c Fix hash table memory leak when restoring PATH 2020-07-09 18:34:15 +01:00
pmain.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
shcomp.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
streval.c silence macro redefinition warnings (re: 7003aba4) 2020-06-16 04:51:21 +02:00
string.c shellquoting: rm redundant iswprint() call (re: f9d28935) 2020-07-16 01:13:59 +01:00
subshell.c Fix possible crash due to failure to update shell FD state 2020-07-10 20:04:31 +01:00
suid_exec.c Fix 39 spelling errors and a formatting issue 2020-06-12 01:45:18 +02:00
tdump.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
timers.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
trestore.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
waitevent.c Version: 2012-08-01-master 2016-01-11 15:54:23 -05:00
xec.c Convert default typeset aliases to regular builtins 2020-07-15 20:54:06 +01:00