Coverity Scan fixes