浏览代码

Final final tweak (hopefully).

Martijn Laan 1 年之前
父节点
当前提交
6c3d3e5399
共有 1 个文件被更改,包括 2 次插入5 次删除
  1. 2 5
      Projects/Src/CmnFunc2.pas

+ 2 - 5
Projects/Src/CmnFunc2.pas

@@ -1830,12 +1830,9 @@ procedure TCreateProcessOutputReader.Read(const LastRead: Boolean);
     if LastRead and (Pipe.Buffer <> '') then begin
       var N := Length(Pipe.Buffer);
       if Pipe.Buffer[N] = #13 then begin
-        { See FindNewLine: the buffer could end with a final #13 which has not yet
-          been handled. Handle it same as a final #13#10 would have been already
-          so log two lines, the second being empty. }
+        { See FindNewLine: the buffer could end with a final #13 which needs to
+          be stripped still }
         Delete(Pipe.Buffer, N, 1);
-        LogLine(Pipe.CaptureList, Pipe.Buffer);
-        Pipe.Buffer := ''; { Will be logged below }
       end;
       LogLine(Pipe.CaptureList, Pipe.Buffer);
     end;