watch: Nearly 30 bugs fixed, code optimized, no feature changes
Bugs fixed (commits in order) (details and non-bugfixes in commit msgs):
- Missing
WITH_WATCH8BIT
separation. -
my_getwc()
: errors whenchar
signed/unsigned, off-by-one inungetc()
. -
wcwidth()
only if!WEOF
, possible misaligned ptr dereference. -
-w
omitting blank line after truncated one,-w
not triggering when wcwide char doesn't fit in last col [#285 (closed)]. - --
- Blank line missing after a completely filled line [BUGS].
- --
-
-g
+-q
now coexist,-d
no longer removes color,-c
+-d
don't mess up diffs,-q
counter doesn't soar when resizing screen,malloc(sizeof(item_ptr))
->malloc(sizeof(*item_ptr))
. Manpage fixes (-x
, BUGS). - No output to hijacked
stdout
/stderr
afterfork()
, no leakage of fds or processes whenEINTR
, undone Debian #240989 (would let unprintables be output, may need review). Manpage fixes (-p
, missingCOLUMNS
andLINES
). -
-qN
becomes-q1
when N<1, don't reset-q
counter when screen resizes. Header: a few text misalignment issues, consider wcwidth whenWITH_WATCH8BIT
,ENOMEM
afterasprintf()
. Manpage fixes (non-existent BUGS). - Consume inadvertent input before exiting on
-e
. -
-d
no longer ignores combining characters [BUGS]. -
-d
now considers full wcwidth of new character. - Orderly recovery from cmd taking longer than
-n
[BUGS]. - --
- --
- --
Edited by Roman Žilka