Various fixes after review.