devel: Applied changes from the coverity_scan branch