File: fd.inc

package info (click to toggle)
cc65 2.19-2
  • links: PTS
  • area: main
  • in suites: forky, sid, trixie
  • size: 20,268 kB
  • sloc: ansic: 117,151; asm: 66,339; pascal: 4,248; makefile: 1,009; perl: 607
file content (21 lines) | stat: -rw-r--r-- 884 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
;
; Christian Groessler, Oct-2000
;
; offsets and defines for fdtable (internal use only)
;

MAX_FD_INDEX    =       12      ; max. # of open fds
MAX_FD_VAL      =       8       ; we have 8 IOCBs

ft_entrylen = 4 ; length of table entry (it's not sufficient to change here!
                ; the code sometimes does two bit shifts to multiply/divide by
                ; this length)

ft_usa  = 0     ; usage counter
ft_iocb = 1     ; iocb index (0,$10,$20,etc.), $ff for empty entry
ft_dev  = 2     ; device of open iocb (0 - device not remembered, eg. filename specified)
ft_flag = 3     ; flags
                ; lower 3 bits: device number (for R: and D:)
                ; bit 3 - seeking supported by DOS/disk combination
                ; bit 4 - indicates a fd opened by the program as apposed to the
                ;         inherited ones from program start (fd 0 to fd 2)