more coverity scan fixes