Skip to content

Commit

Permalink
Initialize DIE to NULL, rather than default constructing, so it's che…
Browse files Browse the repository at this point in the history
…ckable.
  • Loading branch information
wrwilliams committed Oct 31, 2016
1 parent 66207c9 commit 53295ed
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions symtabAPI/src/Module.C
Expand Up @@ -304,7 +304,8 @@ Module::Module() :
language_(lang_Unknown),
addr_(0),
exec_(NULL),
info_is_valid_(false)
info_is_valid_(false),
info_(NULL) // not a default constructed whatever!
{
}

Expand Down Expand Up @@ -434,5 +435,8 @@ bool Module::containsOffset(Dyninst::Offset offset) const {

Module::DebugInfoT Module::getDebugInfo()
{
if(!info_is_valid_) exec_->parseTypesNow(); return info_;
if(!info_is_valid_) {
exec_->parseTypesNow();
}
return info_;
}

0 comments on commit 53295ed

Please sign in to comment.