In system(), avoid depending on the data bank value at entry.

The previous code relied on the data bank value at entry being the bank that contained the library code. This might not be the case when called from code using the large memory model, which could lead to the wrong value being returned.
This commit is contained in:
Stephen Heumann 2021-09-02 17:38:38 -05:00
parent 869f8726a6
commit 9937ef7003
1 changed files with 2 additions and 2 deletions

View File

@ -1593,14 +1593,14 @@ system start
sta exComm+2 sta exComm+2
lb1 phy execute the command lb1 phy execute the command
phx phx
plb
Execute ex Execute ex
ldy empty ldy empty
bne ret if doing system(NULL) bne ret if doing system(NULL)
tya tya
bcs ret error => no command processor bcs ret error => no command processor
inc a (& vice versa) inc a (& vice versa)
ret rtl ret plb
rtl
ex dc i'$8000' ex dc i'$8000'
exComm ds 4 exComm ds 4