sundry improvements

I was planning to make only the most recent fix but found the other two necessary to get started.