Code Analysis ruleset fixes