Fix uninitialized variable
echo | awk 'BEGIN {i=$1; print i}' prints a boatload of stack
garbage. NUL terminate the memory returned from malloc to prevent it.
Obtained from: OpenBSD run.c 1.40
Sponsored by: Netflix
Fix %c for floating values that become 0 when coerced to int.
Obtained from: OpenBSD run.c 1.36 (From Jeremy Devenport)
Sponsored by: Netflix, Inc
Don't display empty error context.
Context extraction didn't handle this case and showed uninitialized memory.
Obtained from: OpenBSD lib.c 1.21
Sponsored by: Netflix
Any specific reason to write the or statement as two separate if clauses?
I believe in other parts we do it ((true & x & y & z) | (false & a & b &c )) - as multiline checks;
I don't like them both get executed "always", so at the very least, an "else" just before the 2nd if would be good.
The logic looks ok to me.