Made two GEOS directory functions return NULL if they can't give a valid entry.

This commit is contained in:
Greg King
2020-10-29 17:54:56 -04:00
parent d8e6fa61bb
commit aad17a6f05
3 changed files with 23 additions and 22 deletions

View File

@@ -1,7 +1,7 @@
;
; Maciej 'YTM/Alliance' Witkowiak
; 1999-10-26, Maciej 'YTM/Alliance' Witkowiak
; 2020-10-29, Greg King
;
; 26.10.99
; struct filehandle* Get1stDirEntry (void);
@@ -15,9 +15,9 @@ _Get1stDirEntry:
jsr Get1stDirEntry
stx __oserror
txa
beq L0 ; error?
jmp return0 ; return NULL
L0: lda r5L
bne L1 ; jump if disk error
lda r5L
ldx r5H
rts
L1: jmp return0 ; return NULL if not valid entry