Browse Source

Fix card_eof error

Scott Lahteine 4 years ago
parent
commit
42fa9fc570
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      Marlin/src/gcode/queue.cpp

+ 1
- 1
Marlin/src/gcode/queue.cpp View File

@@ -526,7 +526,7 @@ void GCodeQueue::get_serial_commands() {
526 526
     while (length < BUFSIZE && !card_eof) {
527 527
       const int16_t n = card.get();
528 528
       card_eof = card.eof();
529
-      if (n < 0) { SERIAL_ERROR_MSG(MSG_SD_ERR_READ); continue; }
529
+      if (n < 0 && !card_eof) { SERIAL_ERROR_MSG(MSG_SD_ERR_READ); continue; }
530 530
       const char sd_char = (char)n;
531 531
       if (sd_char == '\n' || sd_char == '\r' || card_eof) {
532 532
 

Loading…
Cancel
Save