Subversion Repositories Spectranet

[/] [trunk/] [include/] [stat.inc] - Blame information for rev 570

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 215 winston
;The MIT License
2
;
3
;Copyright (c) 2009 Dylan Smith
4
;
5
;Permission is hereby granted, free of charge, to any person obtaining a copy
6
;of this software and associated documentation files (the "Software"), to deal
7
;in the Software without restriction, including without limitation the rights
8
;to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
;copies of the Software, and to permit persons to whom the Software is
10
;furnished to do so, subject to the following conditions:
11
;
12
;The above copyright notice and this permission notice shall be included in
13
;all copies or substantial portions of the Software.
14
;
15
;THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
;IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
;FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
;AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
;LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
;OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
;THE SOFTWARE.
22
 
23
; Definitions for things returned by stat
24
 
25
; Bitmasks for the filemode field.
26
; These are defined by POSIX as a 16 bit octal value. The list below
27
; has been converted to hex, since not all assemblers support octal.
28
S_IFMT          equ     0xF000
29
S_IFSOCK        equ     0xC000
30
S_IFLNK         equ     0xA000
31
S_IFREG         equ     0x8000
32
S_IFBLK         equ     0x6000
33
S_IFDIR         equ     0x4000
34
S_IFCHR         equ     0x2000
35
S_IFIFO         equ     0x1000
36
S_ISUID         equ     0x0800
37
S_ISGID         equ     0x0400
38
S_ISVTX         equ     0x0200
39
S_IRWXU         equ     0x01C0
40
S_IRUSR         equ     0x0100
41
S_IWUSR         equ     0x0080
42
S_IXUSR         equ     0x0040
43
S_IRGRP         equ     0x0020
44
S_IWGRP         equ     0x0010
45
S_IXGRP         equ     0x0008
46
S_IROTH         equ     0x0004
47
S_IWOTH         equ     0x0002
48
S_IXOTH         equ     0x0001
49
 
50 275 winston
; Stat structure offsets
51
STAT_MODE       equ     0x00
52
STAT_UID        equ     0x02
53
STAT_GID        equ     0x04
54
STAT_SIZE       equ     0x06
55
STAT_ATIME      equ     0x0A
56
STAT_MTIME      equ     0x0E
57
STAT_CTIME      equ     0x12
58
STAT_STRINGS    equ     0x16
59