浏览代码

+ Fixed Append() bug. Appending non-existing file now gives an error

michael 24 年之前
父节点
当前提交
25ba6fe2ea
共有 1 个文件被更改,包括 7 次插入7 次删除
  1. 7 7
      rtl/win32/system.pp

+ 7 - 7
rtl/win32/system.pp

@@ -536,15 +536,12 @@ begin
          oflags:=GENERIC_WRITE or GENERIC_READ;
        end;
   end;
-{ standard is opening and existing file }
-  cd:=OPEN_EXISTING;
 { create it ? }
   if (flags and $1000)<>0 then
    cd:=CREATE_ALWAYS
-{ or append ? }
+{ or Append/Open ? }
   else
-   if (flags and $100)<>0 then
-    cd:=OPEN_ALWAYS;
+    cd:=OPEN_EXISTING;
 { empty name is special }
   if p[0]=#0 then
    begin
@@ -1567,7 +1564,10 @@ end.
 
 {
   $Log$
-  Revision 1.19  2001-10-23 21:51:03  peter
+  Revision 1.20  2001-11-07 13:05:16  michael
+  + Fixed Append() bug. Appending non-existing file now gives an error
+
+  Revision 1.19  2001/10/23 21:51:03  peter
     * criticalsection renamed to rtlcriticalsection for kylix compatibility
 
   Revision 1.18  2001/10/09 02:37:29  carl
@@ -1643,4 +1643,4 @@ end.
   Revision 1.2  2000/07/13 11:33:58  michael
   + removed logs
 
-}
+}