Fix a few warnings, and improve a utility script.
Merge from last day at Fathom.