Skip to content

Commit

Permalink
Merge pull request #39 from starius/fix-sanitizer-error
Browse files Browse the repository at this point in the history
fix sanitizer error in test
  • Loading branch information
davenger committed Apr 6, 2016
2 parents 9885488 + c710556 commit ba27b97
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pire/scanner_io.cpp
Expand Up @@ -166,8 +166,8 @@ void LoadedScanner::Load(yistream* s)
Impl::AlignedLoadArray(s, sc.m_letters, MaxChar);
Impl::AlignedLoadArray(s, sc.m_jumps, sc.m.statesCount * sc.m.lettersCount);
if (header.Version == Header::RE_VERSION_WITH_MACTIONS) {
yauto_ptr<Action> actions(new Action[sc.m.statesCount * sc.m.lettersCount]);
Impl::AlignedLoadArray(s, actions.get(), sc.m.statesCount * sc.m.lettersCount);
yvector<Action> actions(sc.m.statesCount * sc.m.lettersCount);
Impl::AlignedLoadArray(s, actions.data(), actions.size());
}
Impl::AlignedLoadArray(s, sc.m_tags, sc.m.statesCount);
sc.m.initial += reinterpret_cast<size_t>(sc.m_jumps);
Expand Down

0 comments on commit ba27b97

Please sign in to comment.