summaryrefslogtreecommitdiff
path: root/rtl
diff options
context:
space:
mode:
authormarco <marco@3ad0048d-3df7-0310-abae-a5850022a9f2>2020-10-11 15:18:17 +0000
committermarco <marco@3ad0048d-3df7-0310-abae-a5850022a9f2>2020-10-11 15:18:17 +0000
commitd717a0f9634ee1e69155da4b762ed77ba013f261 (patch)
treeb501a7df19c17095c27110379259ab11b2593287 /rtl
parent667dfce7dafadeb025426481fb5c411d47afe357 (diff)
downloadfpc-d717a0f9634ee1e69155da4b762ed77ba013f261.tar.gz
# revisions: 47064
git-svn-id: https://svn.freepascal.org/svn/fpc/branches/fixes_3_2@47092 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'rtl')
-rw-r--r--rtl/unix/bunxovl.inc12
1 files changed, 9 insertions, 3 deletions
diff --git a/rtl/unix/bunxovl.inc b/rtl/unix/bunxovl.inc
index 12025aad32..c5774ea3a3 100644
--- a/rtl/unix/bunxovl.inc
+++ b/rtl/unix/bunxovl.inc
@@ -248,10 +248,16 @@ begin
end;
{$endif}
+const
+ { read/write permission for everyone }
+ MODE_FPOPEN = S_IWUSR OR S_IRUSR OR
+ S_IWGRP OR S_IRGRP OR
+ S_IWOTH OR S_IROTH;
+
Function FpOpen (path : pChar; flags : cInt):cInt; {$ifdef VER2_0}inline;{$endif}
begin
- FpOpen:=FpOpen(path,flags,438);
+ FpOpen:=FpOpen(path,flags,MODE_FPOPEN);
end;
Function FpOpen (const path : RawByteString; flags : cInt):cInt; {$ifdef VER2_0}inline;{$endif}
@@ -259,14 +265,14 @@ var
SystemPath: RawByteString;
Begin
SystemPath:=ToSingleByteFileSystemEncodedFileName(path);
- FpOpen:=FpOpen(pchar(SystemPath),flags,438);
+ FpOpen:=FpOpen(pchar(SystemPath),flags,MODE_FPOPEN);
end;
Function FpOpen (path : String; flags : cInt):cInt;
begin
path:=path+#0;
- FpOpen:=FpOpen(@path[1],flags,438);
+ FpOpen:=FpOpen(@path[1],flags,MODE_FPOPEN);
end;
Function FpOpen (path : String; flags : cInt; Mode: TMode):cInt;