fix, linux version, possible desktop cession crash when a runnable module was implicitly aborted

This commit is contained in:
Basile Burg 2015-10-22 00:36:47 +02:00
parent a262a8296f
commit ee4980204d
2 changed files with 5 additions and 1 deletions

View File

@ -990,8 +990,11 @@ begin
//
fname := fRunProc.Executable;
if getprocInputHandler.process = fRunProc then
begin
getMessageDisplay.message('the execution of a runnable module ' +
'has been implicitly aborted', fDoc, amcEdit, amkWarn);
getprocInputHandler.addProcess(nil);
end;
killProcess(fRunProc);
if fileExists(fname) then
if ExtractFilePath(fname) = GetTempDir(false) then

View File

@ -82,7 +82,8 @@ begin
// TODO-cfeature: process list, imply that each TCESynMemo must have its own runnable TProcess
// currently they share the CEMainForm.fRunProc variable.
if fProc <> nil then
fProc.Terminate(1);
if fProc.Running then
fProc.Terminate(0);
txtExeName.Caption := 'no process';
fProc := nil;