Merge pull request #2427 from RosettaCommons/roccomoretti/clangSA_fix Some fixes for Clang Static Analysis