What is the default analysis ruleset for the C++ Static Analysis ?
I can enable is with the
/analyze
flag.
MSDN just says "Turns on analysis in the default mode."
BTW, I know I can enable the analysis in the Code Analysis project property and that works.
What I have tried:
I tried tweaking some of the default ruleset files, but it looks like they are not used.
I even tried to explicitly use the full
/analyze:ruleset NativeMinimumRules.ruleset
flag but it does not work.
The complete line:
/analyze:ruleset "c:\users\lincourM\Desktop\NativeRecommendedRules.ruleset"
the ruleset contains :
<Rule Id="C6001" Action="Error" />
<Rule Id="C6011" Action="Error" />
and I get warnings instead of errors:
1>c:\users\lincourm\documents\project\teststaticanalysis\teststaticanalysis\teststaticanalysis.cpp(9): warning C6011: Dereferencing NULL pointer 'p'. : Lines: 8, 9
1>c:\users\lincourm\documents\project\teststaticanalysis\teststaticanalysis\teststaticanalysis.cpp(23): warning C6001: Using uninitialized memory 'i'.: Lines: 17, 18, 23