Fixes for various tools

See individual commits for details.
Excellent point!