mirror of
https://github.com/irmen/prog8.git
synced 2024-12-26 14:29:35 +00:00
diskio now properly closes files after a load or save
This commit is contained in:
parent
261c0fc9b6
commit
3e63a29c59
@ -97,10 +97,14 @@ io_error:
|
|||||||
plp
|
plp
|
||||||
}}
|
}}
|
||||||
|
|
||||||
|
ubyte result=0
|
||||||
if_cc
|
if_cc
|
||||||
return c64.READST()==0
|
result = c64.READST()==0
|
||||||
|
|
||||||
return false
|
c64.CLRCHN()
|
||||||
|
c64.CLOSE(1)
|
||||||
|
|
||||||
|
return result
|
||||||
}
|
}
|
||||||
|
|
||||||
sub load(ubyte drivenumber, uword filenameptr, uword address_override) -> uword {
|
sub load(ubyte drivenumber, uword filenameptr, uword address_override) -> uword {
|
||||||
@ -122,6 +126,9 @@ io_error:
|
|||||||
+ ldx P8ZP_SCRATCH_REG
|
+ ldx P8ZP_SCRATCH_REG
|
||||||
}}
|
}}
|
||||||
|
|
||||||
|
c64.CLRCHN()
|
||||||
|
c64.CLOSE(1)
|
||||||
|
|
||||||
if end_of_load
|
if end_of_load
|
||||||
return end_of_load - address_override
|
return end_of_load - address_override
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user