From b7dd6ebaa4cf4a6123c289db4f2e17063c663124 Mon Sep 17 00:00:00 2001 From: izydorst Date: Fri, 8 Mar 2002 16:44:07 +0000 Subject: [PATCH] error handling if drive type is unknown git-svn-id: svn://svn.cc65.org/cc65/trunk@1175 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- libsrc/geos/disk/dio_cts.s | 4 +++- libsrc/geos/disk/dio_stc.s | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/libsrc/geos/disk/dio_cts.s b/libsrc/geos/disk/dio_cts.s index f6118641e..c7871045d 100644 --- a/libsrc/geos/disk/dio_cts.s +++ b/libsrc/geos/disk/dio_cts.s @@ -69,7 +69,9 @@ cmp #DRV_1581 beq dio_cts1581 -; unknown device, return what you have got + lda #DEV_NOT_FOUND ; unknown device + ldx #0 + beq ret dio_ctsend: ldy #1 diff --git a/libsrc/geos/disk/dio_stc.s b/libsrc/geos/disk/dio_stc.s index ea6369fde..c64bb0802 100644 --- a/libsrc/geos/disk/dio_stc.s +++ b/libsrc/geos/disk/dio_stc.s @@ -66,7 +66,9 @@ cmp #DRV_1581 beq dio_stc1581 -; ... + lda #DEV_NOT_FOUND ; unknown device + ldx #0 + beq _ret dio_stcend: ldy #diopp_track -- 2.39.5