2 ; Ullrich von Bassewitz, 17.06.1998
5 ; /* Find a free descriptor slot */
18 Loop: and __filetab + _FILE::f_flags,y ; load flags
19 beq Found ; jump if closed
20 .repeat .sizeof(_FILE)
23 cpy #(FOPEN_MAX * .sizeof(_FILE)) ; Done?
30 ; Free slot found, get address
35 ldx #>__filetab ; High byte
36 bcc @L1 ; Jump if no overflow