浏览代码

* fix for double-write bug, probably in since r1353

git-svn-id: trunk@2869 -
marco 19 年之前
父节点
当前提交
eb5d494b12
共有 1 个文件被更改,包括 5 次插入2 次删除
  1. 5 2
      rtl/win32/crt.pp

+ 5 - 2
rtl/win32/crt.pp

@@ -670,10 +670,13 @@ begin
   GetScreenCursor(CurrX, CurrY);
   GetScreenCursor(CurrX, CurrY);
   s:='';
   s:='';
   for i:=0 to f.bufpos-1 do
   for i:=0 to f.bufpos-1 do
-    if f.buffer[i]<#32 then
+    if f.buffer[i] in [#7,#8,#10,#13] then // special chars directly.
       begin
       begin
         if s<>'' then
         if s<>'' then
-          WriteStr(s);
+          begin
+            WriteStr(s);
+ 	    s:='';
+          end;
         WriteChar(f.buffer[i]);
         WriteChar(f.buffer[i]);
       end
       end
     else
     else