Commit Graph

1670 Commits

Author SHA1 Message Date
tg
6eed6635e9 check for -xipo on SUNWcc (needs -xO4 though, which I refuse to enable
automatically)
2010-01-28 15:12:34 +00:00
tg
fa63e3ba13 grml, better. 2010-01-27 18:36:19 +00:00
tg
d489a0153c document an annoying ^Z bug
(I think this is because the TAND and the Job are not visible to
the code at the same time; patches welcome, as usual)

I don't think this is related to ^Z'd systrace(1)'d programmes
sometimes being unawakable, though.
2010-01-27 18:16:14 +00:00
tg
2765a07564 when using persistent history (and not MKSH_SMALL), let the shells
concurrently accessing the same $HISTFILE be more synchronised with
each other: empty lines (just pressing Return) and duplicates (that
are split and written twice by the lines loaded from $HISTFILE in
the meantime); requested by Maximilian “mxey” Gaß in #!/bin/mksh
2010-01-25 16:12:57 +00:00
tg
f3b3b4b1fb remove some debugging code 2010-01-25 14:38:04 +00:00
tg
bbb4a1a70f add Loaathash1 (iv=0x100 ipv 0) 2010-01-25 14:29:34 +00:00
tg
2e9654ffa4 introduce “typeset -i foo[*]”, rationale see cid 1004B5DA60A56BFB604 2010-01-25 14:25:16 +00:00
tg
c700693d11 Add “unset foo[*]” mksh extension, which allows to unset the *contents*
of foo[0] (but not its attributes), and the rest of the array, so that
later “set +A foo bar” will set foo[0]=bar but retain the attributes.

This is important, because, in the future, arrays will have different
attributes per element, instead of all the same (which, actually, is
not entirely true right now either, since “unset foo[0]” will not mo-
dify the attributes of a foo[1] existing at that point in time), where
foo[$newkey] will inherit from foo[0], but typeset foo will only affect
foo[0] no longer foo[*] in the future. (The rules about typeset=local
will still apply, as they affect creation of variables in a scope.)
2010-01-25 14:11:29 +00:00
tg
1ac42c1c1c fix © year 2010-01-25 14:07:39 +00:00
tg
c9ac50df02 use conftest.c ipv scn.c since that’s recognised by at least ccache as magic 2010-01-25 12:16:04 +00:00
tg
a82dc41e99 add an explicit message when mirtoconf+siglist generation are done 2010-01-19 14:26:24 +00:00
tg
559125f5f9 RCSID sync (oksh bumped their array limit again… wonder when………) 2010-01-16 19:08:05 +00:00
tg
833810a154 While we were supposed to use Ctrl-Arrowkey for wordwise jumping,
some idiotic terminal emulators and/or people seem to use the es-
cape codes normally denoting Alt-Arrowkey instead so let's simply
bind them to the vt_hack as well... (untested)
2010-01-08 22:21:06 +00:00
tg
1baed92a90 document that mksh evaluates namerefs lazily but ksh93 doesn't 2010-01-06 18:29:01 +00:00
tg
df4137c2e2 I don't care that AT&T ksh93 fails this nameref test case, but
it's important and we'll want it.
2010-01-04 21:08:00 +00:00
tg
18754d1cf8 __attribute__((used)) is not for pcc (but unused works) 2010-01-01 18:27:42 +00:00
tg
0611ecad1f make [[ -o ‣-U ]] = [[ -o ‣+U ]] = [[ -o ‣utf8-mode ]]
where ‘‣’ is either nothing, ‘!’ or ‘?’ as usual.
2010-01-01 18:02:01 +00:00
tg
6115f5a91c • re-implement wcswidth-like behaviour for ${%foo} even in !UTFMODE
• merge the rest of branch tg-wcswidth-behaviour
• enhance test cases for wcswidth-like behaviour
• switch hash table collision resolution algorithm to Python’s as announced
• bump vsn
2010-01-01 17:44:10 +00:00
tg
c413edb34a jobs.c: apply patch from deraadt@o:
│remember to restore errno (ie. stop someone from making a mistake later)
│ok guenther
check.t, sh.h: bump vsn

I wonder though why errno must be restored even if nothing was
called after reading it… moid?
2009-12-31 14:05:44 +00:00
tg
01823e0e11 use [[ -o … ]] instead of [[ $- = *U* ]] manipulation 2009-12-12 22:27:14 +00:00
tg
769e222586 re-vamp __attribute__ handling; let this pass on HP-UX bundled compiler
as well as HP aCC
2009-12-12 22:27:10 +00:00
tg
0c3acb2374 HP-UX IA64: +DD64 is no longer necessary with aCC (no gcc available…) 2009-12-12 21:17:25 +00:00
tg
c49852b4dc Revision 1.38: [7]download - view: [8]text, [9]markup, [10]annotated - [11]select for diffs
Sat Dec 12 04:28:44 2009 UTC (13 hours, 14 minutes ago) by deraadt
   Branches: [12]MAIN
   CVS tags: [13]HEAD
   Diff to: previous 1.37: [14]preferred, [15]coloured
   Changes since revision 1.37: +2 -3 lines
a dangling do / while that was very very ugly
2009-12-12 17:45:42 +00:00
tg
a77bbf6123 HP aCC tells me I'm using "const" twice, and /usr/ccs/bin/cc even
errors out here. Let's hope that this form will *still* have the
entirety of that array in .rodata...

XXX more to come, thanks to HP DSPP PvP, e.g. __attribute__ stuff
2009-12-08 19:23:34 +00:00
tg
09bda13970 memmove not memcpy, src/dst overlap 2009-12-05 22:24:35 +00:00
tg
65a3713605 strchr related fixes 2009-12-05 22:19:42 +00:00
tg
df51db99c9 another Valgrind würgaround 2009-12-05 22:03:39 +00:00
tg
703551bd4f attempt a better fix: break off widthadj upon encountering NUL,
add remaining columns as octets (should also speed optimise)
2009-12-05 20:17:59 +00:00
tg
86d4dee0da valgrind (thanks ciruZ for trying) found uninitialised memory use
in utf_skipcols by x_goto
2009-12-05 19:44:09 +00:00
tg
8213a28403 llvm/clang scan-build is now content… 2009-12-05 17:43:50 +00:00
tg
437f9b76e1 clangs static analyser says these are dead stores 2009-12-05 17:02:25 +00:00
tg
37b1260d13 unbreak test.sh in some cases 2009-12-05 16:19:59 +00:00
tg
f7ef72cbd7 Kürzen! 2009-12-05 13:02:26 +00:00
tg
417fd60c76 * fix 'set -A foo -- [2]=a b c' contingency (tested against GNU bash4,
which, in its latest sid incarnation, even received mksh's ability
  to produce ${!foo[*]} array keys, wow!)
* plug a memory leak while here (ATEMP only, but still)
2009-12-01 19:15:35 +00:00
tg
0f10db42ef explicit cast, since Bionic headers aren’t type safe, apparently 2009-12-01 13:12:30 +00:00
tg
24b48aeb3f this better be const, too 2009-11-29 17:37:22 +00:00
tg
fa3acb939b fix 'mksh -U -i' and 'mksh +U -i' 2009-11-28 15:38:30 +00:00
tg
a09f05e77a /me is annoyed
I read, IIRC in the Cederqvist, that 'cvs tag' sets a sticky tag onto
the cwd… it doesn’t, apparently. (I actually like it better this way,
but one needs to know!)
2009-11-28 14:28:03 +00:00
tg
883d9d99b3 switch ${%foo} to wcswidth-like behaviour – slightly problematic, and
the “set +U” case isn’t even handled

committed to branch because I’d like to get more input on this, for now
2009-11-28 14:21:47 +00:00
tg
7063a9a921 lintian: hyphen-used-as-minus-sign 2009-11-23 12:49:55 +00:00
tg
68b81a10bc fix a warning from MirDebian mksh_39.9.20091122-0wtf1:
../../mksh/misc.c:586: warning: pointer targets in passing argument 1 of 'utf_ptradj' differ in signedness
2009-11-23 12:48:19 +00:00
tg
29176a176f fix more manpages 2009-11-22 18:23:38 +00:00
tg
4cff10296b bump vsn 2009-11-22 14:25:18 +00:00
tg
22ff50fe55 IFS (even in AT&T ksh93) are octets, so 'IFS=…' isn’t possible atm 2009-11-22 14:23:21 +00:00
tg
09b96b8fc7 25 is a better (POSIX) CHILD_MAX 2009-11-22 14:14:42 +00:00
tg
e240e62a55 don't tell lies 2009-11-22 14:13:38 +00:00
tg
ccc6f6de86 prevent buffer underrun reads, ok bsiegert@ 2009-11-22 13:49:04 +00:00
tg
2094e3f25c since we have wcwidth anyway, expose it as ${%strvar} to the user, iff
utf8-mode is enabled (otherwise it'll be a synonym for ${#strvar} aka
the number of octets in it)
2009-11-21 23:23:20 +00:00
tg
aa31a51e5f sync with reality 2009-11-21 23:21:23 +00:00
tg
398b5b7a60 fix that as well 2009-11-21 22:32:08 +00:00