adapt to new oserror/errno handling

git-svn-id: svn://svn.cc65.org/cc65/trunk@4732 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cpg
2010-07-06 22:43:19 +00:00
parent ae98a6db40
commit e673b53850
5 changed files with 20 additions and 25 deletions

View File

@@ -21,10 +21,7 @@
; seeking not supported, return -1 and ENOSYS errno value
no_supp:jsr incsp6
lda #<ENOSYS
jsr __seterrno ; set __errno, return zero in A
sta __oserror
lda #$FF
tax
jsr __directerrno ; returns with $FFFF in AX
sta sreg
sta sreg+1
rts
@@ -93,8 +90,14 @@ end: ldx tmp3
bpl l01
; error returned from CIO
xxerr: sty __oserror
bmi iocberr
xxerr: tya
pha
jsr incsp6
pla
jsr __mappederrno ; returns with $FFFF in AX
sta sreg
sta sreg+1
rts
; check for offset 0, SEEK_CUR (get current position)
cont: ldy #3