CMP_TREE_MODEL*: fix uninitialized members

Coverity CID 157141
Coverity CID 157136
This commit is contained in:
Chris Pavlina 2017-03-11 19:22:42 -05:00
parent fe4f02f5b9
commit 5e5259b59c
3 changed files with 6 additions and 2 deletions

View File

@ -104,6 +104,7 @@ int CMP_TREE_NODE::Compare( CMP_TREE_NODE const& aNode1, CMP_TREE_NODE const& aN
CMP_TREE_NODE::CMP_TREE_NODE()
: Parent( nullptr ),
Type( INVALID ),
IntrinsicRank( 0 ),
Score( kLowestDefaultScore ),
Alias( nullptr ),

View File

@ -76,7 +76,7 @@ class LIB_ALIAS;
class CMP_TREE_NODE {
public:
enum TYPE {
ROOT, LIB, ALIAS, UNIT
ROOT, LIB, ALIAS, UNIT, INVALID
};
CMP_TREE_NODE* Parent; ///< Parent node or null

View File

@ -82,7 +82,10 @@ CMP_TREE_MODEL_ADAPTER::CMP_TREE_MODEL_ADAPTER( PART_LIBS* aLibs )
:m_filter( CMP_FILTER_NONE ),
m_show_units( true ),
m_libs( aLibs ),
m_preselect_unit( 0 )
m_preselect_unit( 0 ),
m_col_part( nullptr ),
m_col_desc( nullptr ),
m_widget( nullptr )
{}