Minor bug fixes to various things.