Age | Commit message (Collapse) | Author | |
---|---|---|---|
2023-07-23 | avoid MAIL* environment variables to save a few bytes in install media | Klemens Nanni | |
ksh(1) MAIL, MAILCHECK, MAILPATH mbox handling is useless in the installer. OK miod deraadt | |||
2021-03-05 | Fix old ksh bug: wrong variable being looked up when value is provided. | Vadim Zhukov | |
This results, e.g., in allowing the first item of a read-only array to be overwritten, as found by Jordan Geoghegan. okay tb@ | |||
2020-02-21 | Enforce that TMOUT is an integer literal to prevent command execution from | Theo Buehler | |
the environment at shell initialization time. During startup, ksh calls 'eval typeset -i TMOUT="${TMOUT:-0}"'. which allows command injection via arithmetic expansion, e.g., by setting TMOUT to 'x[`/bin/echo Hi >&2`]'. Problem noted by Andras Farkas and tj, inspired by a similar issue in AT&T's ksh. Tested in snaps for two weeks. "go for it" deraadt | |||
2018-06-18 | Use shl_out->fd instead of STDOUT_FILENO in the call the setupterm(). | Todd C. Miller | |
Suggested by anton@ | |||
2018-06-18 | Add clear-screen emacs editing command, currently not bound to a | Todd C. Miller | |
key by default. The shell will query the terminfo database to find the escape sequence to clear the screen. OK deraadt@ | |||
2018-04-13 | Count $SECONDS with CLOCK_MONOTONIC. | cheloha | |
Keeps $SECONDS advancing uniformly and independent of wall clock jumps. ok jca@ | |||
2018-04-09 | Support 64 bit integers on 32 bit architectures. | Tobias Stoeckmann | |
No binary change on amd64 and there should be no differences on any other 64 bit architecture either (because long = int64_t). ok cheloha, tb | |||
2018-03-15 | Favor usage of __func__ in warning/error messages. Some of them referred to the | anton | |
wrong function and fix the rest for consistency. Diff from Michael W. Bombardieri with some cosmetic cleanup applied. ok benno@ tb@ | |||
2018-01-16 | Introduce internal_warningf() and mark internal_errorf() as noreturn | Jeremie Courreges-Anglas | |
This helps tools like scan-build, and follows the example of warningf() and errorf(). ok anton@ | |||
2018-01-15 | Stop pretending we support building ksh without EDIT/HISTORY support | Jeremie Courreges-Anglas | |
ok anton@ | |||
2018-01-06 | Bring back the sign compare changes, this time with a fix from otto@ | Todd C. Miller | |
that fixes the issues seen on hppa. OK deraadt@ otto@ | |||
2018-01-04 | Back out sign compare changes that appear to cause problems on hppa. | Todd C. Miller | |
Requested by deraadt@ | |||
2018-01-01 | Add WARNINGS=yes to ksh and fix the resulting sign compare warnings. | Todd C. Miller | |
OK tb@ | |||
2017-12-27 | Add -Wshadow to Makefile and fix the resulting warnings. Many of | Todd C. Miller | |
the warnings are due to the use of globals with generic names, specifically "options" and "path". I've renamed "options" to "sh_options" since it holds the shell options and "path" to "search_path". OK jca@ tb@ | |||
2017-08-30 | Implement HISTCONTROL ignoredups & ignorespace features | Jeremie Courreges-Anglas | |
ignoredups: don't save the current line if it is identical to the last history line. ignorespace: don't save the current line if it starts with a space ok anton@ millert@ | |||
2017-08-30 | No need for NULL checks before afree() | Jeremie Courreges-Anglas | |
2016-09-08 | Add KSH_IGNORE_RDONLY flag and use it in var.c instead of the 0x4 | Todd C. Miller | |
magic number. | |||
2016-09-08 | Allow "typeset -ir FOO" if FOO is not already marked read-only. OK tb@ | Todd C. Miller | |
2015-12-30 | rename global "e" to genv to avoid accidental shadowing and aliasing. | Ted Unangst | |
ok millert nicm tb | |||
2015-12-14 | Move system headers from sh.h to those files that actually need them. | tb | |
ok mmcc@ a while ago | |||
2015-10-19 | Move string.h include from sh.h to the files that use it. | mmcc | |
ok nicm@ | |||
2015-10-19 | Move limits.h include from sh.h to the files that actually need it. No | mmcc | |
binary change. ok nicm@ | |||
2015-10-19 | Apply style(9) to header includes. | mmcc | |
ok nicm@ | |||
2015-09-22 | Make errorf() and bi_errorf() handle a NULL argument. | Todd C. Miller | |
From Michael McConville; OK nicm@ | |||
2015-09-18 | Last of the (thing *)0 -> NULL, from Michael McConville. No binary | Nicholas Marriott | |
change. | |||
2015-09-17 | Remove unnecessary casts, from Michael McConville. No binary change. | Nicholas Marriott | |
2015-09-15 | correct spelling of NULL from (char *)0. from Michael McConville. | Ted Unangst | |
ok md5 | |||
2015-09-14 | Replace Tflag typedef with just int; ok tedu | Nicholas Marriott | |
2015-09-14 | Apply the ancient art of tedu to ksh_limval.h. ok guenther | Nicholas Marriott | |
2015-09-10 | Kill another superfluous variable initialization; from Michael McConville. | Jeremie Courreges-Anglas | |
2015-09-01 | remove casts and null checks before free. from Michael McConville | Ted Unangst | |
ok deraadt | |||
2015-08-19 | Don't re-include headers pulled by "sh.h". (I actually don't like this .h | Theo de Raadt | |
pulls in system .h pattern) | |||
2015-04-17 | Use getint() instead of intval() for parsing the columns variable, | Theo de Raadt | |
allowing the addition of more accurate bounds and garbage checks. ok millert | |||
2014-12-12 | Range check the value of the base for typeset -i base x=y. Instead of | Jonathan Gray | |
erroring for values outside of the range switch to base 10 to match the behaviour of ksh93. As we have a smaller digit alphabet than ksh93 the accepted range is smaller (2-36) than ksh93 (2-64). The other form of setting a base, typeset -i x=base#y already has a range check that errors (as ksh93 also does for that syntax). Fixes a crash found with the afl fuzzer. | |||
2014-12-08 | Don't need special complex rand vs arc4random code. If the | Theo de Raadt | |
standards-mandated "seed" method is used, simply call srand_deterministic() and the subsystem switches out of strong random mode into C89 crap mode. ok millert | |||
2013-12-20 | Fix a crash in ksh when trying to access ${12345678901234567890} | Vadim Zhukov | |
Input from deraadt@, millert@ and otto@. okay from millert@ plus a willing from deraadt@ | |||
2013-12-18 | Remove artificial limit on the max array index. | Todd C. Miller | |
Adapted from a bitrig commit from Martin Natano. OK zhuk@ | |||
2013-12-17 | ctype cleanups. Repeated re-audits of this sensitive area by okan and | Theo de Raadt | |
myself, with a variety of other people spending some time as well. Thanks. | |||
2013-04-05 | SECONDS is, in a highly theoretical way, not y2k38 safe. comment it. | Ted Unangst | |
2007-10-15 | specifying int instead of just unsigned is better style | Theo de Raadt | |
2007-08-02 | backout last change; iff is right. | Federico G. Schwindt | |
prompted by deraadt@ | |||
2007-08-02 | while i'm here: iff -> if | Federico G. Schwindt | |
2007-08-02 | fix memory leaks and one potential null deref found by coverity. from netbsd. | Federico G. Schwindt | |
millert@ ok | |||
2006-05-21 | Set the index of item[0], since it might not have been set before | Otto Moerbeek | |
(A=0; A[1]=1) and do not use a static buffer in str_val, since the results might be used in a loop. Report from jared r r spiegel; help from Matthias Kilian; ok beck@ | |||
2006-03-13 | Interpret zero-filled numbers as decimal; PR 4213; from Alexey | Otto Moerbeek | |
Dobriyan; ok millert@ moritz@ jaredy@ | |||
2005-12-11 | fix a few name clashes with libc; found by lint. ok deraadt@ | Otto Moerbeek | |
2005-10-08 | Tell user which value of index is out of bounds. ok deraadt@ | Otto Moerbeek | |
2005-03-30 | lots of indentation cleanup, now ksh is readable like our other code. | Theo de Raadt | |
double checked to make sure no binaries change, and eyed by niallo | |||
2005-03-28 | spacing | Theo de Raadt | |
2005-03-28 | spacing | Theo de Raadt | |