Fix some more problems reported by coverity.