From bb0bc955f5b22dda6cc37428f2ad5f71172b4cff Mon Sep 17 00:00:00 2001 From: Richard Cornwell Date: Sat, 7 Mar 2020 14:22:51 -0500 Subject: [PATCH] ICL1900: Fixed load file error message. --- ICL1900/icl1900_sys.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ICL1900/icl1900_sys.c b/ICL1900/icl1900_sys.c index aa70891..f4d80c3 100755 --- a/ICL1900/icl1900_sys.c +++ b/ICL1900/icl1900_sys.c @@ -283,6 +283,8 @@ sim_load(FILE * fileref, CONST char *cptr, CONST char *fnam, int flag) /* Convert bits into image */ memset(image, 0, sizeof(image)); for (j = 0; j < 80; j++) { + if (buffer[j] == '\r' && buffer[j+1] == '\n') + break; if (buffer[j] == '\n') break; if ((buffer[j] & 0377) == 0243) @@ -311,6 +313,8 @@ sim_load(FILE * fileref, CONST char *cptr, CONST char *fnam, int flag) /* Convert bits into image */ memset(image, 0, sizeof(image)); for (j = 0; j < 80; j++) { + if (buffer[j] == '\r' && buffer[j+1] == '\n') + break; if (buffer[j] == '\n') break; if ((buffer[j] & 0377) == 0243)