summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/gui/fpg_memo.pas2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/fpg_memo.pas b/src/gui/fpg_memo.pas
index 789da3c3..8863ca67 100644
--- a/src/gui/fpg_memo.pas
+++ b/src/gui/fpg_memo.pas
@@ -542,7 +542,7 @@ var
begin
if ReadOnly then
Exit;
- if FSelEndLine < 0 then
+ if (FSelEndLine < 0) or (FSelStartLine<0) then
Exit;
if (FSelStartLine shl 16) + FSelStartPos <= (FSelEndLine shl 16) + FSelEndPos then