d8662eb228
even more hacks to pass “-O666 -fstrict-overflow -Wstrict-overflow=9 -flto=jobserver” with “gcc version 4.8.0 20120930 (experimental) [trunk revision 191865] (Debian 20120930-1)” ☹ plus make the rtchecks mandatory
2012-10-03 17:24:23 +00:00
c39bfe09ee
rewrite some code to avoid gcc 4.8 complaining
2012-10-03 16:16:15 +00:00
b55d9870e3
reorder notoktomul to have the constant as second argument like notoktoadd
2012-10-03 15:55:37 +00:00
0575d07671
rewrite XPtrV to use size_t instead of pointer arithmetic, for gcc-snapshot (20120930-1) -fstrict-overflow -Wstrict-overflow=9
2012-10-03 15:50:32 +00:00
167995da22
repair choiceless select builtin
2012-10-03 15:13:34 +00:00
9fbdef8e60
pure RCSID sync with OpenBSD, as we introduced SIGWINCH tracking earlier
...
XXX we could track whether tty_fd has already been successfully opened,
XXX the ttystate initialised, and then just never close it unless it is
XXX necessary, then we can keep COLUMNS/LINES accurate in scripts, even
2012-09-21 17:20:22 +00:00
eac85ffdf1
OpenBSD found out that "building argv for $* and $@" manipulates l->argv
...
in place which affects ps(1) output on BSD; create a new array and copy
the original parts from argv[] there without touching argv passed to main
2012-09-07 21:02:43 +00:00
0415b74436
Update wcwidth data from Unicode 6.1.0
2012-09-01 23:46:41 +00:00
e6ddeaa53d
sync clog
2012-08-24 21:33:51 +00:00
e2d1f3bf99
related to LP#1025843 fix tab completion for tilde
...
this code is insane, who wrote globbing and expansion for mksh’s
predecessor must have been on very interesting drugs
2012-08-24 21:15:42 +00:00
42ac0dc08e
second attempt at getting '$FOO/b*r/baz' tab-completed right,
...
plus the beginning of the tilde fix… do not use, this is fucking
impossible to get right, but I’d like an archival commit
2012-08-24 20:57:46 +00:00
2ed6e8998c
repair globbing $foo/ba*r/baz
2012-08-24 20:05:13 +00:00
84020897fd
allow overriding /etc location (LP#1039713), but don’t do it
2012-08-24 19:09:10 +00:00
beca8ed86f
more int → bool
2012-08-24 19:02:57 +00:00
bb5e56d4c4
remove ${ foo;} from mksh again due to buffering issues jilles found
2012-08-17 18:34:25 +00:00
f18b1fae85
bump
2012-08-03 18:45:32 +00:00
9b7b7f742e
implement ksh93 feature ${ foo;}
2012-07-30 21:37:17 +00:00
0db4002bd6
remove unused flag
2012-07-30 17:04:31 +00:00
aedb299057
note that some longjmp don’t handle 0 properly
...
cf. <500C1B2E.9030602@zytor.com >
2012-07-22 15:56:51 +00:00
058e7f8ed4
do implement quoting, as ${foo@Q} though, as hommage at mirmake
...
dedicate this “release” to Andi
and use tomorrow’s (UTC) day for version, to cover up my debian fuckup
2012-07-20 23:22:13 +00:00
4778a2a62f
lesson learned from http://k1024.org/~iusty/blog/entry/perf-null/ – add -DMKSH_SMALL_BUT_FAST which gives more speed (8/20K less cycles, 5/9K less insns, 1.8/2.4k less branches, 65/275 less branch misses) on Debian/amd64 (klibc-static/eglibc) at cost of 0/2 more page faults and 6K/6K more text size
2012-07-01 15:55:00 +00:00
516678f4fd
imply MKSH_CONSERVATIVE_FDS by MKSH_LEGACY_MODE, too
2012-07-01 15:44:31 +00:00
35c65bb568
bugfix: make CONSERVATIVE_FDS implied by MKSH_SMALL actually work
2012-07-01 15:41:56 +00:00
67714b270a
dissolve the hashtab nonsense, ¾ is good, and mirkev will also use that
2012-07-01 15:38:09 +00:00
c1f821d4e5
(mksh) tighten 32-bit requirements; (lksh) switch to long; allow any bitness
2012-06-28 20:17:39 +00:00
ea01d80833
hackish work-around the lexer to make alias definitions in mksh -c
...
work (Closes : #517009 ) and mention in the manpage why they sometimes
do not work (doing so for COMSUBs is not worth the effort)
2012-06-28 20:05:11 +00:00
dc5ae267ce
make tempvar() and vtemp global
2012-06-28 20:02:29 +00:00
45fba44292
sync w/ oksh (RCSID only # no change needed)
2012-06-28 20:01:01 +00:00
1fa4453946
mh… all I’m gonna hack on upstream today… fix -t for manpage generation and cleanup code snippets; bump vsn; sync clog
2012-06-26 19:33:33 +00:00
c212458922
bump for mksh with lksh-except-long, so we get the ball moving
2012-06-26 18:11:05 +00:00
967e929e98
add basic LEGACY KSH mode (Build.sh -L), no changes yet
2012-06-25 16:05:10 +00:00
6f1078606e
bump after dealing with all things Benny had Coverity find
...
remainging CIDs not listed are either
• false positive (bug in coverity)
• intentional (possibly with lint override coverity doesn't parse)
• VLA (XXX find out how to mix C99 and ANSI VLAs)
• things flagged as possible resource leaks I have no idea about
(no biggie though, and only in error cases I think)
2012-06-24 20:39:26 +00:00
3125146b43
Fix typeset issues (LP: #993847 )
...
This was actually more evil:
• use a recursive function to display blocks in reverse order,
so that local variable values overwrite global ones
• add array support to typeset -p (from typeset -p -)
• display 'set -A varname' line before setting values, for -p
• if -p got arguments, only display those (from the innermost scope)
Also, the usual amount of code cleanup…
2012-05-09 23:21:00 +00:00
ea8f29f428
sprinkle CONSERVATIVE_FDS for many older OSes; DISABLE_TTY_WARNING for BeOS and Coherent (probably more to come); NO_CMDLINE_EDITING to Plan 9; put Hurd NO_PATH_MAX into MKSH__ private namespace
2012-05-05 17:37:44 +00:00
f34cae3997
keep up
2012-05-04 22:44:34 +00:00
e6ace01f12
last parts of Coherent patchkit: O_ACCMODE and termio
2012-05-04 22:18:27 +00:00
fef3808126
more symlink(7) nonexistence support code
2012-05-04 22:05:02 +00:00
7beac6668d
provide for Coherent not having gettimeofday(2), imake style (bad, but this is not for others to use without a second thought anyway)
2012-05-04 21:47:04 +00:00
2d31aca859
more int→bool while trying to let ^D output CR+LF (which shan’t be, oh my…)
2012-05-04 21:15:34 +00:00
5780bc5eb7
new MKSH_NO_CMDLINE_EDITING to disable command line editing in its entirety
...
mainly for the Plan 9 port though it may also help the WinAPI variant,
other porting efforts, as well as a new project I cannot say yet
2012-05-04 20:49:08 +00:00
7c4bf78446
move bi_getn from misc.c to funcs.c and make it static
...
even antique gcc versions will usually inline it now
2012-05-04 20:08:25 +00:00
b67de6ba17
add experimental code to use sigprocmask+pause+sigprocmask ipv sigsuspend (and harden j_sigchld handler for that) to improve working on BeOS 5.0 and Coherent UNIX, found by RT
2012-04-27 16:16:23 +00:00
5204e7cc4f
after discussion with ciruZ, switch mksh from NZAT to NZAAT fully
...
to get rid of the bias introduced by making the hash never zero
… he also pointed out a memory (heap) usage optimisation… which
may impact code size a bit though as I’d need to pass an additional
argument on hashtable function calls… or, forgo the benefit of not
having to pointer-align the key in the structure, which can be as
much as 3/7 octets per item, heap storage… OTOH the saved space is
4/8 octets per not-allocated item, possibly some code (use of an
multiply-add opcode), but the function call overhead/cost would
possibly be quite a bit… I guess I’ll have to measure…
2012-04-22 21:50:35 +00:00
5eea59ad57
rewrite maketemp() obsoleting tempnam(3) and mkstemp(3) external deps
2012-04-14 16:07:48 +00:00
70e6988d25
factor out rndget() code, for adding users
...
XXX in the future, the entire scheme must be rethinked when we need more
XXX entropy for the hash tables; possibly a cheap add using NZAT and re-
XXX initialise the LCG only on access and when added (so keep NZAT state
XXX separate from LCG state); also, then we will need a more elaborate
XXX scheme, such as adding from environment, editor keypresses and timing
2012-04-14 14:35:13 +00:00
b49abfac18
genericise MKSH_NO_SIGSETJMP
2012-04-14 14:07:47 +00:00
29e4269f33
if the OS does not provide sig_atomic_t and/or ssize_t, you can now define
...
MKSH_TYPEDEF_SIG_ATOMIC_T and MKSH_TYPEDEF_SSIZE_T via CPPFLAGS to the
*correct* definitions (it’s absolutely critical they be correct!)
2012-04-14 14:02:40 +00:00
5b4d0dbbc5
drop all deprecated code, you have been warned
2012-04-07 11:19:53 +00:00
5d4492608a
more speling
2012-04-06 15:23:11 +00:00
3d3081115b
if LDSTATIC is not empty (i.e. "-static" or " "), always add “our” sources:
...
• strlcpy
• utf_wcwidth
note strchr/strstr from misc.c are still #ifdef DEBUG only, as they are
not eligible: they’re for const-cleanliness debugging purposes
XXX get rid of multiple occurrences of binary search code, too…
2012-04-06 15:20:42 +00:00