Преглед изворни кода

* flush std handlers at thread termination

git-svn-id: trunk@4752 -
florian пре 19 година
родитељ
комит
262f60e67d
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      rtl/inc/thread.inc

+ 5 - 0
rtl/inc/thread.inc

@@ -82,6 +82,11 @@ end;
 procedure EndThread(ExitCode : DWord);
 
 begin
+  { Make sure that all output is written to the redirected file }
+  Flush(Output);
+  Flush(ErrOutput);
+  Flush(StdOut);
+  Flush(StdErr);  
   CurrentTM.EndThread(ExitCode);
 end;