home *** CD-ROM | disk | FTP | other *** search
-
- * Maxon C++ Library:
- * Modul "fileerr"
- * Jens Gelhar 08.06.92, 08.04.94
-
- str_error = 7
- str_bufptr = 8
-
- buf_fill = 6
- buf_pos = 8
- buf_mode = 10
-
- xdef _clearerr,clearerr__P06stream
- xdef _feof,feof__P06stream
- xdef _ferror,ferror__P06stream
-
- _clearerr:
- clearerr__P06stream:
- move.l 4(a7),a0
- clr.b str_error(a0)
- rts
-
- _feof:
- feof__P06stream:
- move.l 4(a7),a0
- cmp.b #-1,str_error(a0)
- seq d0
- ext.w d0
- ext.l d0
- bra.b validerr
-
- _ferror:
- ferror__P06stream:
- move.l 4(a7),a0
- moveq #0,d0
- move.b str_error(a0),d0
- cmp.w #$FF,d0
- bne.b ret
- moveq #0,d0
- validerr
- tst.w d0
- beq.b ret
- move.l str_bufptr(a0),d1 ; Buffer gesetzt?
- beq.b ret
- move.l d1,a0
- tst.b buf_mode(a0) ; Lesepuffer?
- bpl.b ret
- move.w buf_pos(a0),d1 ; noch was drin?
- cmp.w buf_fill(a0),d1
- bhs.b ret
- moveq #0,d0 ; dann vorerst kein Problem
- ret rts
-
- end
-
-