Skip to content

cppcheck and clang static analyzer warnings that need a look #66

@seanm

Description

@seanm

I fixed some cppcheck and clang static analyzer warnings, but others need someone that knows the code:

The enclosing 'for' loop goes to m_NDims (the ivar), should be _nDims (the param)?

src/metaImage.cxx:584:18: Assigned value is garbage or undefined
src/metaImage.cxx:590:25: Assigned value is garbage or undefined

These may be dead code, or something is failing to use those results...

src/metaImage.cxx:1205:5: Value stored to 'posend' is never read
src/metaImage.cxx:2908:9: Value stored to 'fileImageDim' is never read
src/metaImage.cxx:3044:9: Value stored to 'maxV' is never read

redundantAssignment,src/metaImage.cxx:3051,style,Variable 'maxV' is reassigned a value before the old one has been used.
unreadVariable,src/metaImage.cxx:1205,style,Variable 'posend' is assigned a value that is never used.
unreadVariable,src/metaImage.cxx:1290,style,Variable 'elementDataFileName' is assigned a value that is never used.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions