From 32a9847825935dc60b7e9a400bd9683d45e5f29c Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Sun, 8 Mar 2009 09:26:32 +0000 Subject: Fix from John Ehresman to be safe when calling AutoCompleteGetCurrent when no autocompletion is active. --- src/ScintillaBase.cxx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/ScintillaBase.cxx b/src/ScintillaBase.cxx index d2b6a3ed8..31e580336 100644 --- a/src/ScintillaBase.cxx +++ b/src/ScintillaBase.cxx @@ -386,6 +386,8 @@ void ScintillaBase::AutoCompleteCompleted() { } int ScintillaBase::AutoCompleteGetCurrent() { + if (!ac.Active()) + return -1; return ac.lb->GetSelection(); } -- cgit v1.2.3