Commits


man9: rename IM to MR Commit d32deab17bfffa5bffc5fab3e6577558e40888c5 renamed IM to MR but these man pages were missed.


htmlroff: fix array bounds


eqn: enlarge errbuf to account for large tokens


xd: fix swizz8 loop counting


libhtml: fix array bounds in lex


libthread: call setpgrp in programs that will background This fixes the 'run stats from rc; exit rc; stats dies' problem. It's unclear whether this is the right fix or whether rc should be starting all its interactive commands in their own process groups. But at least it does fix stats dying.


sam: avoid out-of-bounds read in rterm Usually r->nused < r->nalloc and the read is in bounds. But it could in theory be right on the line and reading past the end of the allocation. Make it safe but preserve as much of the old semantics as possible. This use of rterm appears to be only for optimization purposes so the result does not matter for correctness.


sam: remove backward ?: The exit code here is ignored anyway.


rc: do not exit on EINTR from read This happens if lldb attaches to rc.


lib9: reject postnote with special pids


auxstats: do not postnote 0


acme, sam, samterm: remove weird switch usage For whatever reason all three of these programs contain switches like: switch(x) { case 1: if(cond) case 2: f(); } Like Duff's device, this is legal C but more obscure than it really needs to be. This commit assumes those are intended as written and simply writes them more clearly. I did consider that maybe they are mistakes, but in the case of sam/regexp.c, my rewrite in this commit matches the acme/regx.c that has been in plan9port since I added acme in 2003. (I didn't bother to dig up the old Plan 9 releases.) Assuming acme/regx.c has been correct for the past two decades, this commit should be correct too.


sam: rm dregs


stats: add threadmaybackground


acme: allow @ in file names For upspin and other tools that put email addresses in names.