From 047a034477c07bc7298ca3c7da5477da2d462f0d Mon Sep 17 00:00:00 2001 From: paul Date: Fri, 28 Nov 2008 03:36:23 +0000 Subject: [PATCH] synedit: fix range check errors git-svn-id: trunk@17619 - --- components/synedit/synedit.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/synedit/synedit.pp b/components/synedit/synedit.pp index a828812c13..edf4485f78 100644 --- a/components/synedit/synedit.pp +++ b/components/synedit/synedit.pp @@ -8185,12 +8185,12 @@ begin ecSetMarker0..ecSetMarker9,ecToggleMarker0..ecToggleMarker9: begin if BookMarkOptions.EnableKeys then begin - if Command in [ecSetMarker0..ecSetMarker9] then + if (Command >= ecSetMarker0) and (Command <= ecSetMarker9) then CX := Command - ecSetMarker0 else CX := Command - ecToggleMarker0; if assigned(fBookMarks[CX]) then begin - moveBkm := (Command in [ecSetMarker0..ecSetMarker9]) + moveBkm := ((Command >= ecSetMarker0) and (Command <= ecSetMarker9)) or (fBookMarks[CX].Line <> CaretY); ClearBookMark(CX); if moveBkm then