Do not enter the editor with a negative file displacement.

This could happen due to errors on the command line, e.g.:

cmpl +T +E file.c cc=(invalid)
This commit is contained in:
Stephen Heumann 2022-10-22 12:54:59 -05:00
parent 946c6c1d55
commit 859aa4a20a

View File

@ -816,6 +816,8 @@ var
msgGS: gsosInString; {message}
begin {ExitToEditor}
if disp < 0 then {sanity check disp}
disp := 0;
msgGS.size := length(msg^); {set up the error message}
msgGS.theString := msg^;
liDCBGS.org := disp; {mark the error}