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

@@ -16,7 +16,7 @@
.import clriocb
.import fddecusage,newfd
.import findfreeiocb
.import __do_oserror,incsp4
.import incsp4
.import ldaxysp,addysp
.import __oserror
.importzp tmp4,tmp2
@@ -38,7 +38,7 @@ parmok: jsr findfreeiocb
beq iocbok ; we found one
lda #<EMFILE ; "too many open files"
seterr: jsr __seterrno
seterr: jsr __directerrno
jsr incsp4 ; clean up stack
lda #$FF
tax
@@ -143,7 +143,8 @@ finish: php
bpl ok
jsr fddecusage ; decrement usage counter of fd as open failed
jmp __do_oserror
tya ; put error code into A
jmp __mappederrno
ok: lda tmp2 ; get fd
ldx #0