Fix some code analysis warnings and enable the recommended rule set on builds