Avoid indirect jmp with unknown vector address.
This commit is contained in:
@@ -107,7 +107,7 @@ exit: ldx #$02
|
|||||||
txs ; Re-init stack pointer
|
txs ; Re-init stack pointer
|
||||||
|
|
||||||
; We're done
|
; We're done
|
||||||
jmp (done)
|
jmp done
|
||||||
|
|
||||||
.segment "INIT"
|
.segment "INIT"
|
||||||
|
|
||||||
@@ -148,8 +148,8 @@ init: ldx #zpspace-1
|
|||||||
; No BASIC.SYSTEM so quit to ProDOS dispatcher instead
|
; No BASIC.SYSTEM so quit to ProDOS dispatcher instead
|
||||||
lda #<quit
|
lda #<quit
|
||||||
ldx #>quit
|
ldx #>quit
|
||||||
sta done
|
sta done+1
|
||||||
stx done+1
|
stx done+2
|
||||||
|
|
||||||
; No BASIC.SYSTEM so use addr of ProDOS system global page
|
; No BASIC.SYSTEM so use addr of ProDOS system global page
|
||||||
lda #<$BF00
|
lda #<$BF00
|
||||||
@@ -202,8 +202,8 @@ q_param:.byte $04 ; param_count
|
|||||||
|
|
||||||
.data
|
.data
|
||||||
|
|
||||||
; Location to jump to when we're done
|
; Final jump when we're done
|
||||||
done: .addr DOSWARM
|
done: jmp DOSWARM ; Potentially patched at runtime
|
||||||
|
|
||||||
.segment "ZPSAVE"
|
.segment "ZPSAVE"
|
||||||
|
|
||||||
|
|||||||
@@ -161,8 +161,8 @@ setbuf: lda #$00 ; Low byte
|
|||||||
; Call loader stub after C libary shutdown
|
; Call loader stub after C libary shutdown
|
||||||
lda #<target
|
lda #<target
|
||||||
ldx #>target
|
ldx #>target
|
||||||
sta done
|
sta done+1
|
||||||
stx done+1
|
stx done+2
|
||||||
|
|
||||||
; Initiate C libary shutdown
|
; Initiate C libary shutdown
|
||||||
jmp _exit
|
jmp _exit
|
||||||
|
|||||||
@@ -16,6 +16,6 @@ initreboot:
|
|||||||
; Quit to PWRUP
|
; Quit to PWRUP
|
||||||
lda #<$FAA6
|
lda #<$FAA6
|
||||||
ldx #>$FAA6
|
ldx #>$FAA6
|
||||||
sta done
|
sta done+1
|
||||||
stx done+1
|
stx done+2
|
||||||
rts
|
rts
|
||||||
|
|||||||
Reference in New Issue
Block a user