.include "errno.inc"
.include "fcntl.inc"
.include "_file.inc"
+ .include "stat.inc"
; ------------------------------------------------------------------------
tya
iny
sta (sp),y
- ldy #4 ; Size of arguments in bytes
+ lda #<(S_IREAD|S_IWRITE)
+ ldx #>(S_IREAD|S_IWRITE)
+ jsr pushax ; Push the "mode" argument onto the stack
+ ldy #6 ; Size of arguments in bytes
jsr _open ; Will cleanup the stack
; Check the result of the open() call