Procházet zdrojové kódy

+ *stat* wrappers

git-svn-id: trunk@1229 -
florian před 20 roky
rodič
revize
3e5bb17b2c
2 změnil soubory, kde provedl 44 přidání a 6 odebrání
  1. 38 0
      packages/base/libc/sstat.inc
  2. 6 6
      packages/base/libc/sstath.inc

+ 38 - 0
packages/base/libc/sstat.inc

@@ -42,3 +42,41 @@ function S_ISSOCK(mode : __mode_t) : boolean;
 begin
    S_ISSOCK:=__S_ISTYPE(mode,__S_IFSOCK);
 end;
+
+
+function fstat(__fd:longint; __buf:Pstat):longint;
+  begin
+    __fxstat(_STAT_VER,__fd,__buf);
+  end;
+
+
+function lstat(__file:Pchar; __buf:Pstat):longint;
+
+  begin
+    __lxstat(_STAT_VER,__file,__buf);
+  end;
+
+
+function stat(__file:Pchar; __buf:Pstat):longint;
+  begin
+    __xstat(_STAT_VER,__file,__buf);
+  end;
+
+
+function fstat64(__fd:longint; __buf:Pstat64):longint;
+  begin
+    __fxstat64(_STAT_VER,__fd,__buf);
+  end;
+
+
+function lstat64(__file:Pchar; __buf:Pstat64):longint;
+
+  begin
+    __lxstat64(_STAT_VER,__file,__buf);
+  end;
+
+
+function stat64(__file:Pchar; __buf:Pstat64):longint;
+  begin
+    __xstat64(_STAT_VER,__file,__buf);
+  end;

+ 6 - 6
packages/base/libc/sstath.inc

@@ -48,14 +48,14 @@ const
   DEFFILEMODE = ((((S_IRUSR or S_IWUSR) or S_IRGRP) or S_IWGRP) or S_IROTH) or S_IWOTH;
   S_BLKSIZE = 512;
 
-function stat(__file:Pchar; __buf:Pstat):longint;cdecl;external clib name 'stat';
-function fstat(__fd:longint; __buf:Pstat):longint;cdecl;external clib name 'fstat';
+function stat(__file:Pchar; __buf:Pstat):longint;
+function fstat(__fd:longint; __buf:Pstat):longint;
 
-function stat64(__file:Pchar; __buf:Pstat64):longint;cdecl;external clib name 'stat64';
-function fstat64(__fd:longint; __buf:Pstat64):longint;cdecl;external clib name 'fstat64';
+function stat64(__file:Pchar; __buf:Pstat64):longint;
+function fstat64(__fd:longint; __buf:Pstat64):longint;
 
-function lstat(__file:Pchar; __buf:Pstat):longint;cdecl;external clib name 'lstat';
-function lstat64(__file:Pchar; __buf:Pstat64):longint;cdecl;external clib name 'lstat64';
+function lstat(__file:Pchar; __buf:Pstat):longint;
+function lstat64(__file:Pchar; __buf:Pstat64):longint;
 
 function chmod(__file:Pchar; __mode:__mode_t):longint;cdecl;external clib name 'chmod';
 function fchmod(__fd:longint; __mode:__mode_t):longint;cdecl;external clib name 'fchmod';