1. 07 Jan, 2019 1 commit
  2. 30 Nov, 2018 1 commit
  3. 21 Nov, 2018 1 commit
  4. 19 Sep, 2018 1 commit
  5. 26 Jul, 2018 1 commit
    • Sean McBride's avatar
      Fixed misc issues found by cppcheck 1.84 · 38f25cd2
      Sean McBride authored
      Also update suppressions.
      
      This fixed issues were:
      
      identicalInnerCondition,Wrapping/Tools/vtkWrapHierarchy.c:457,warning,Identical inner 'if' condition is always true.
      
      missingOverride,IO/ADIOS/FunctionPointers.h:114,style,The function 'operator()' overrides a function in a base class but is not marked with a 'override' specifier.
      
      uninitMemberVar,IO/Image/vtkMRCReader.cxx:133,warning,Member variable 'vtkInternal::header' is not initialized in the constructor.
      
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::CellArrays' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::FieldArrays' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::GridsCache' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::MaxDepth' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::NumProcs' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::PointArrays' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::Rank' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::SetsCache' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Xdmf3/vtkXdmf3LightDataHandler.cxx:70,warning,Member variable 'vtkXdmf3LightDataHandler::SILBuilder' is not initialized in the constructor.
      
      uninitMemberVarPrivate,IO/Geometry/vtkOpenFOAMReader.cxx:4424,warning,Member variable 'vtkOpenFOAMReaderPrivate::NumTotalAdditionalCells' is not initialized in the constructor.
      uninitMemberVarPrivate,IO/Geometry/vtkOpenFOAMReader.cxx:4424,warning,Member variable 'vtkOpenFOAMReaderPrivate::Parent' is not initialized in the constructor.
      38f25cd2
  6. 04 Apr, 2018 1 commit
    • Sean McBride's avatar
      Fixed a few cppcheck warnings, some new from version 1.83; suppressed others · 2c582d48
      Sean McBride authored
      The fixed warnings were:
      
      knownConditionTrueFalse,Filters/ParallelGeometry/vtkPUnstructuredGridGhostCellsGenerator.cxx:399,style,Condition 'inputGridCopy' is always false
      
      useInitializationList,Common/Math/vtkQuaternionInterpolator.cxx:41,performance,Variable 'Q' is assigned in constructor body. Consider performing initialization in initialization list.
      
      uninitMemberVar,Filters/Modeling/vtkContourLoopExtraction.cxx:210,warning,Member variable 'vtkContourLoopExtraction::DataSetBounds' is not initialized in the constructor.
      
      uninitMemberVar,Filters/Modeling/vtkContourLoopExtraction.cxx:210,warning,Member variable 'vtkContourLoopExtraction::DataDimension' is not initialized in the constructor.
      
      uninitMemberVar,Filters/Modeling/vtkContourLoopExtraction.cxx:210,warning,Member variable 'vtkContourLoopExtraction::Bounds' is not initialized in the constructor.
      2c582d48
  7. 08 Mar, 2018 1 commit
    • Sean McBride's avatar
      Updated cppcheck suppressions; fixed some warnings · 077b5d5a
      Sean McBride authored
      Updated some suppressions:
      - removed some that are fixed by 1.82
      - for some useful warnings that were totally suppressed, now only suppress them in files where actual errors currently exist, thus allowing us to stop new such ones being added
      
      Fixed some warnings:
      - a few invalidPointerCast warnings
      - branch where ‘node_name’ string is used uninitialized
      - dead variable, dead store
      - removed unused ivar
      077b5d5a
  8. 25 Jan, 2018 2 commits
    • Allison Vacanti's avatar
      Fully remove the deprecated vtkHyperOctree class. · 4445ca1b
      Allison Vacanti authored
      vtkHyperTreeGrid is the replacement for this class.
      4445ca1b
    • Sean McBride's avatar
      Updates for new cppcheck 1.82 · 5a55f3a6
      Sean McBride authored
      - fixed one warning about division by 0 from public API:
      
      Rendering/Label/vtkLabeledTreeMapDataMapper.cxx:656: style: Public interface of vtkLabeledTreeMapDataMapper is not safe. When calling vtkLabeledTreeMapDataMapper::SetFontSizeRange(), if parameter delta is 0 that leads to division by zero.
      
      - removed suppressions for false positives that are now fixed
      - added suppressions for new false positives
      5a55f3a6
  9. 05 Dec, 2017 1 commit
  10. 15 Oct, 2017 1 commit
    • Sean McBride's avatar
      Fixed numerous warnings from the new cppcheck 1.81 · 442381f5
      Sean McBride authored
      Specifically:
      
      very strange braces!
      syntaxError,Common/DataModel/vtkHyperTreeGrid.cxx:699,error,syntax error
      
      changed size()>0 to !empty()
      stlSize,Filters/General/vtkLoopBooleanPolyDataFilter.cxx:1426,performance,Possible inefficient checking for 'nocellregion' emptiness.
      
      This useless flag has been there since code was added in 2000 in f50b0909
      knownConditionTrueFalse,Common/DataModel/vtkPointLocator.cxx:323,style,Condition 'flag' is always true
      knownConditionTrueFalse,Common/DataModel/vtkPointLocator.cxx:415,style,Condition 'flag' is always true
      knownConditionTrueFalse,Common/DataModel/vtkStaticPointLocator.cxx:788,style,Condition 'flag' is always true
      knownConditionTrueFalse,Common/DataModel/vtkStaticPointLocator.cxx:879,style,Condition 'flag' is always true
      
      This useless 'result' has been there since code was added in 2003 in dd39b9e4
      knownConditionTrueFalse,IO/XML/vtkXMLRectilinearGridReader.cxx:236,style,Condition 'result' is always true
      knownConditionTrueFalse,IO/XML/vtkXMLRectilinearGridReader.cxx:245,style,Condition 'result' is always true
      knownConditionTrueFalse,IO/XML/vtkXMLRectilinearGridReader.cxx:254,style,Condition 'result' is always true
      
      New check in cppcheck 1.81, block is indeed dead code:
      oppositeInnerCondition,Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx:272,warning,Opposite inner 'if' condition leads to a dead code block.
      oppositeInnerCondition,Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx:293,warning,Opposite inner 'if' condition leads to a dead code block.
      oppositeInnerCondition,Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx:349,warning,Opposite inner 'if' condition leads to a dead code block.
      
      false positive, suppressed with zero initialization:
      uninitvar,Filters/Statistics/vtkKMeansStatistics.cxx:810,error,Uninitialized variable: curDistance
      uninitvar,Filters/Statistics/vtkKMeansStatistics.cxx:812,error,Uninitialized variable: curDistance
      
      free(NULL) is allowed, so just remove null check
      knownConditionTrueFalse,IO/Geometry/Testing/Cxx/TestIncrementalOctreePointLocator.cxx:920,style,Condition 'truthIds' is always false
      knownConditionTrueFalse,IO/Geometry/Testing/Cxx/TestIncrementalOctreePointLocator.cxx:956,style,Condition 'diskFile' is always false
      
      Simplified the calculation, verified same codegen on x86_64 with godbolt
      shiftTooManyBitsSigned,Rendering/Volume/vtkHAVSVolumeMapper.cxx:53,error,Shifting signed 32-bit value by 31 bits is undefined behaviour
      
      These have all been thus since their inception, but a global search find the same pattern in TestDijkstraGraphGeodesicPath.cxx, from which I copied the apparent solution
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestPolygonalRepresentationHandleWidget.cxx:119,style,Condition 'distanceOffsetSpecified' is always false
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestPolygonalRepresentationHandleWidget.cxx:199,style,Condition 'distanceOffsetSpecified' is always false
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestPolygonalSurfaceConstrainedDistanceWidget.cxx:244,style,Condition 'distanceOffsetSpecified' is always false
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestPolygonalSurfaceConstrainedDistanceWidget.cxx:325,style,Condition 'distanceOffsetSpecified' is always false
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestSurfaceConstrainedHandleWidget.cxx:117,style,Condition 'distanceOffsetSpecified' is always false
      knownConditionTrueFalse,Interaction/Widgets/Testing/Cxx/TestSurfaceConstrainedHandleWidget.cxx:189,style,Condition 'distanceOffsetSpecified' is always false
      
      Toggle with #if instead
      knownConditionTrueFalse,Imaging/Hybrid/vtkSurfaceReconstructionFilter.cxx:300,style,Condition 'orientationPropagation' is always true
      
      Added parens
      clarifyCalculation,Common/DataModel/vtkLagrangeWedge.cxx:906,style,Clarify calculation precedence for '/' and '?'.
      442381f5
  11. 17 Aug, 2017 1 commit
  12. 05 Jul, 2017 1 commit
  13. 26 May, 2017 1 commit
  14. 14 May, 2017 1 commit
  15. 13 Apr, 2017 1 commit
    • Sean McBride's avatar
      Fixed various warnings from new cppcheck 1.78 · 25058c30
      Sean McBride authored
      Types of warnings:
      - mismatch between parameters names in declaration vs definition
      - make certain parameters references, or const references
      - checking array index after its use
      - prefer preincrement
      - change return type of operator=
      
      There are some very minor API chages here (const/reference).
      25058c30
  16. 18 Jan, 2017 1 commit
    • Sean McBride's avatar
      Update cppcheck suppressions · 9f52f6bc
      Sean McBride authored
      - suppress remaining dashboard false positive about case labels
      - Andrew fixed all postfixOperator warnings, so unsuppressed.
      - duplInheritedMember are pretty serious, so unsuppress to get on dashboard.
      9f52f6bc
  17. 16 Jan, 2017 1 commit
  18. 14 Jan, 2017 1 commit
    • Sean McBride's avatar
      Fixed various cppcheck warnings, suppressed others · 930c68bd
      Sean McBride authored
      - Avoid cppcheck false positive (due to pointer aliasing confusion). Reworked the code so g doesn’t alias gTmp, so that cppcheck doesn’t think that gTmp is used unititialized.
      - added seemingly missing break
      - removed store to local variable from a macro
      - fixed other warnings.
      930c68bd
  19. 10 Jan, 2017 1 commit
    • Sean McBride's avatar
      Fixed many trivial cppcheck 1.77 warnings · ea372f58
      Sean McBride authored
      These are all new warnings vs the previous version, 1.76.1
      
      No real bugs found/fixed here.
      
      Most are either overwriting a never-read variable value,
      usually only at intialiazation, or a useless comparison.
      
      In a couple of places, threw in a const or did other minor reworking.
      ea372f58
  20. 19 Dec, 2016 1 commit
    • Sean McBride's avatar
      Update cppcheck suppressions list · 8d6fcd5b
      Sean McBride authored
      1.76.1 has many less false positives than previous versions,
      so remove suppressed ones that no longer trigger.
      
      For others that I hope are fixed one day, suppress less
      broadly, by file or folder, instead of everywhere.
      8d6fcd5b
  21. 24 Aug, 2016 1 commit
  22. 17 Aug, 2016 1 commit
  23. 10 Aug, 2016 1 commit
  24. 08 Jul, 2016 1 commit
  25. 18 May, 2016 1 commit
  26. 13 May, 2016 1 commit
  27. 30 Apr, 2016 1 commit
  28. 23 Mar, 2016 1 commit
  29. 08 Mar, 2016 1 commit
  30. 22 Feb, 2016 3 commits
  31. 09 Feb, 2016 1 commit
  32. 08 Feb, 2016 1 commit
  33. 31 Jan, 2016 1 commit
  34. 20 Jan, 2016 1 commit
  35. 21 Nov, 2015 1 commit
  36. 05 Nov, 2015 1 commit