0

This call to CppCheck reports 16 errors: cppcheck -j 4 path --enable=all --inconclusive -UIMAQ_IMPORT -UIMAQ_STDCALL -iExternals --xml --xml-version=2 Source 2> cppcheck.xml

The same call to CppCheck but with header folders added using -I reports 10 errors. Length of string is 1392. cppcheck -j 4 path --enable=all --inconclusive -I "C:\ProgramData\National Instruments\CVI2017\include" -I "C:\Program Files (x86)\National Instruments\Vision\Include" -I "C:\Program Files (x86)\National Instruments\CVI2017\toolslib\toolbox" -I "C:\Program Files (x86)\National Instruments\CVI2017\include" -I "C:\Program Files (x86)\National Instruments\CVI2017\include\ansi" -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Externals\iBase\source\testBench -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Externals\iBase\source\tsMis -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Externals\iBase\source -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Release\Bin -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Source\gplib\source -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Source\gplib -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Source\Panels -I D:\Jenkins_DO_NOT_REMOVE\workspace\Production_Radar_77GHz_SWLoadDispatch_1_2_Alfa_Romeo_FCA\Source -UIMAQ_IMPORT -UIMAQ_STDCALL --xml --xml-version=2 -iExternals Source --force 2> cppcheck.xml

Errors from two modules are not reported although the modules ar analyzed according to the log.

1 Answers1

0

It would make sense. The -I is for include. Without it, syntax\classes would look invalid. You should check whether the missing errors can be explained by inclusion of header files.

Nimantha
  • 6,405
  • 6
  • 28
  • 69
  • The missing errors are in two modules. Both modules are analyzed according ot log and have .h-files in folders included with -I – Bengt Nilsson Jun 29 '21 at 09:56
  • Okay, but the .h files may include other .h and so on. This may have effect on how code is analyzed. If you can give example that would be great. Or you can take **all** required files and put them in same folder and see (but I suspect that is going to be almost impossible) –  Jun 29 '21 at 12:22