diff options
author | nyamatongwe <unknown> | 2010-08-29 21:40:07 +1000 |
---|---|---|
committer | nyamatongwe <unknown> | 2010-08-29 21:40:07 +1000 |
commit | 5898e8b0194c712514c93cd675d9102fb3dcd35a (patch) | |
tree | 8ad21c33fd67ba7c3103caebdb11fb9f23c00b30 /src/PerLine.cxx | |
parent | 305c6bea757514e0aa9950c102a1cc20c47b6757 (diff) | |
download | scintilla-mirror-5898e8b0194c712514c93cd675d9102fb3dcd35a.tar.gz |
Fixed crash when lexer asks for line state of negative line. Better to just return 0.
Diffstat (limited to 'src/PerLine.cxx')
-rw-r--r-- | src/PerLine.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/PerLine.cxx b/src/PerLine.cxx index 59d7882cd..8fc6e2531 100644 --- a/src/PerLine.cxx +++ b/src/PerLine.cxx @@ -322,6 +322,8 @@ int LineState::SetLineState(int line, int state) { } int LineState::GetLineState(int line) { + if (line < 0) + return 0; lineStates.EnsureLength(line + 1); return lineStates[line]; } |