1
0
mirror of https://github.com/dschmenk/PLASMA.git synced 2025-01-12 04:30:42 +00:00

Fix line editing and loadmod error checking

This commit is contained in:
David Schmenk 2014-06-04 08:44:04 -07:00
parent a4efc25d4e
commit b73cbbe358

View File

@ -511,13 +511,13 @@ def rdstr(prompt)
repeat
ch = cin
when ch
is $08 ; right arrow
is $15 ; right arrow
if inbuff.0 < maxlen
inbuff.0 = inbuff.0 + 1
ch = inbuff[inbuff.0]
cout(ch)
fin
is $15 ; left arrow
is $08 ; left arrow
if inbuff.0
cout('\\')
cout(inbuff[inbuff.0])
@ -709,6 +709,9 @@ def loadmod(mod)
;
dcitos(mod, @filename)
rdlen = (finddirentry(@filename)):$15
if perr
return -perr
fin
if rdlen > 0
readfile(@filename, heap)
modsize = (heap):0