diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2016-01-13 20:06:56 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2016-01-13 20:06:56 +0000 |
commit | 7fed546d1996271dabc7cf71d4d033125c4da4ee (patch) | |
tree | 2b6dc7dcb4a6380cb331aded15f5a81c0038e194 /source/Symbol/LineTable.cpp | |
parent | 9e6d35490a6542f9c97607f93c2ef8ca8e03cbcc (diff) |
Notes
Diffstat (limited to 'source/Symbol/LineTable.cpp')
-rw-r--r-- | source/Symbol/LineTable.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/Symbol/LineTable.cpp b/source/Symbol/LineTable.cpp index 01c171886430..f9a42a7d14af 100644 --- a/source/Symbol/LineTable.cpp +++ b/source/Symbol/LineTable.cpp @@ -143,6 +143,13 @@ LineTable::InsertSequence (LineSequence* sequence) entry_collection::iterator end_pos = m_entries.end(); LineTable::Entry::LessThanBinaryPredicate less_than_bp(this); entry_collection::iterator pos = upper_bound(begin_pos, end_pos, entry, less_than_bp); + + // We should never insert a sequence in the middle of another sequence + if (pos != begin_pos) { + while (pos < end_pos && !((pos - 1)->is_terminal_entry)) + pos++; + } + #ifdef LLDB_CONFIGURATION_DEBUG // If we aren't inserting at the beginning, the previous entry should // terminate a sequence. |