aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexlib/SparseState.h
diff options
context:
space:
mode:
authorBen Bluemel <ben1982@gmail.com>2011-08-05 23:54:55 +0100
committerBen Bluemel <ben1982@gmail.com>2011-08-05 23:54:55 +0100
commit0594e9947eb0cca93104cd0f986185eb8c2b3117 (patch)
tree6830ba07c71d8c854a7b55e1c2414849386f8f46 /lexlib/SparseState.h
parent1a88b79d0151cf39b0dbe3c0da0858669de13896 (diff)
downloadscintilla-mirror-0594e9947eb0cca93104cd0f986185eb8c2b3117.tar.gz
Fix to check for other.states.empty() when Merging SparseStates.
Diffstat (limited to 'lexlib/SparseState.h')
-rw-r--r--lexlib/SparseState.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lexlib/SparseState.h b/lexlib/SparseState.h
index 655d7429c..08ff104d3 100644
--- a/lexlib/SparseState.h
+++ b/lexlib/SparseState.h
@@ -92,7 +92,7 @@ public:
changed = true;
}
typename stateVector::const_iterator startOther = other.states.begin();
- if (!states.empty() && states.back().value == startOther->value)
+ if (!states.empty() && !other.states.empty() && states.back().value == startOther->value)
++startOther;
if (startOther != other.states.end()) {
states.insert(states.end(), startOther, other.states.end());