Misc. fixes after code review.