diff --git a/compiler/res/prog8lib/diskio.p8 b/compiler/res/prog8lib/diskio.p8 index a4b4f6cbb..cd027299a 100644 --- a/compiler/res/prog8lib/diskio.p8 +++ b/compiler/res/prog8lib/diskio.p8 @@ -395,9 +395,10 @@ _end rts goto io_error while not c64.READST() { - @(messageptr) = c64.CHRIN() - if @(messageptr) in "\r\n" + first_byte = c64.CHRIN() + if first_byte=='\r' or first_byte=='\n' break + @(messageptr) = first_byte messageptr++ } @(messageptr) = 0