home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / SASC6574.LZX / include / stat.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-04-04  |  1.5 KB  |  60 lines

  1. /* Copyright (c) 1992-1993 SAS Institute, Inc., Cary, NC USA */
  2. /* All Rights Reserved */
  3.  
  4. #ifndef _STAT_H
  5. #define _STAT_H 1
  6.  
  7. #ifndef _INO_T
  8. #define _INO_T 1
  9. typedef unsigned long ino_t;
  10. #endif
  11.  
  12. #ifndef _DEV_T
  13. #define _DEV_T 1
  14. typedef long dev_t;
  15. #endif
  16.  
  17. #ifndef _OFF_T
  18. #define _OFF_T 1
  19. typedef long off_t;
  20. #endif
  21.  
  22. #ifndef _COMMTIME_H
  23. #include <sys/commtime.h>
  24. #endif
  25.  
  26. struct stat {
  27.     unsigned short    st_mode;         /* file mode */
  28.     ino_t             st_ino;          /* inode number */
  29.     dev_t             st_dev;          /* file system identifier */
  30.     char              *st_rdev;        /* device identifier (volume name) */
  31.     short             st_nlink;        /* number of links */
  32.     unsigned short    st_uid;          /* file owner user-id */
  33.     unsigned short    st_gid;          /* file group user-id */
  34.     off_t             st_size;         /* file size in bytes */
  35.     time_t            st_atime;        /* time last accessed */
  36.     time_t            st_mtime;        /* time last modified */
  37.     time_t            st_ctime;        /* time last status change */
  38.     short             st_type;         /* Amiga file type */
  39.     char              *st_comment;     /* Amiga file comment */
  40. };
  41.  
  42.  
  43. int stat(const char *, struct stat *);
  44. int lstat(const char *, struct stat *);
  45. int fstat(int, struct stat *);
  46.  
  47.  
  48. /***
  49. *     The following defines can be used to test st_dev.
  50. ***/
  51.  
  52. #define  OFS     0x444F5300      /*  Old File System (Floppy)  */
  53. #define  FFS     0x444F5301      /*  Fast File System  */
  54.  
  55. #ifndef _COMMIFMT_H
  56. #include <sys/commifmt.h>
  57. #endif
  58.  
  59. #endif
  60.