RM:Bug fix in CS.QUIT

This commit is contained in:
Rémy GIBERT 2016-03-18 17:34:30 +01:00
parent 7b4619df80
commit 9fbb48d143

View File

@ -32,18 +32,13 @@ CS.START cld
.DA CS.RUN .DA CS.RUN
.DA CS.DOEVENT .DA CS.DOEVENT
.DA CS.QUIT .DA CS.QUIT
L.MSG.USAGE .DA MSG.USAGE
L.MSG.OK .DA MSG.OK L.MSG.OK .DA MSG.OK
L.MSG.ERR .DA MSG.ERR L.MSG.ERR .DA MSG.ERR
L.FullPath .DA FullPath L.FullPath .DA FullPath
.DA 0 .DA 0
*-------------------------------------- *--------------------------------------
CS.INIT lda #0 CS.INIT ldy #S.PS.hARGS
ldy #DS.END-DS.START-1
.11 sta (pData),y
dey
bpl .11
ldy #S.PS.hARGS
lda (pPs),y lda (pPs),y
beq .98 beq .98
@ -80,7 +75,9 @@ CS.INIT lda #0
clc clc
rts rts
.98 lda #SYSMGR.ERRSYN .98 >LDYA L.MSG.USAGE
>SYSCALL SYS.PSTRoutYA
lda #SYSMGR.ERRSYN
.99 sec .99 sec
rts rts
*-------------------------------------- *--------------------------------------
@ -207,22 +204,23 @@ CS.DOEVENT ldy #S.EVT.hDEV is Event from active IN device?
*-------------------------------------- *--------------------------------------
CS.QUIT ldy #hS.LISTDIR CS.QUIT ldy #hS.LISTDIR
lda (pData),y lda (pData),y
beq .1
>SYSCALL SYS.ListDirCloseA >SYSCALL SYS.ListDirCloseA
ldy #hDIRPATH .1 ldy #hDIRPATH
lda (pData),y lda (pData),y
beq .3 beq .2
>SYSCALL SYS.FreeMemA >SYSCALL SYS.FreeMemA
.3 clc .2 clc
rts rts
*-------------------------------------- *--------------------------------------
CS.END CS.END
MSG.USAGE >PSTRING "Usage : RM [file/Dir, *,? wildcards allowed]\n"
MSG.OK >PSTRING " [Ok]\n" MSG.OK >PSTRING " [Ok]\n"
MSG.ERR >PSTRING " [%h]\n" MSG.ERR >PSTRING " [%h]\n"
FullPath .BS 64 FullPath .BS 64
*-------------------------------------- *--------------------------------------
.DUMMY .DUMMY
.OR 0 .OR 0