khval / AmosKittens

Amos interpreter under development, most commands are support, some extensions are supported.
MIT License
10 stars 3 forks source link

BUG in "Open In" or "input$" command #47

Closed khval closed 2 years ago

khval commented 2 years ago

Describe the bug:

This is the code that is not working:

Trap Open in 1,"file" prefs=asc(input$(1,1)) for a=0 to 7 trap line input #1,prefs$(A) next a close 1

File is not opend, and I get a error on input$(1,1), i need to check if input$(1,1) should give a error or not. Also need to check if file was opened or, if it failed becouse some other error.

khval commented 2 years ago

This bug now fixed. (fgets needs size of the buffer, not length of string as input.)