Remove duplicit incrementation of consecutive comment lines
It was left in the code in one of the refactoring/optimization passes. It really didn't do any harm, but was limiting the performance of the skipping algorithm. + some verification code added - will be removed after successful tests
This commit is contained in:
parent
caf58b16b6
commit
15d76a7501
1 changed files with 3 additions and 1 deletions
|
@ -151,7 +151,9 @@ int16_t SdFile::readFilteredGcode(){
|
||||||
if( ! gfEnsureBlock() )goto eof_or_fail; // fetch it into RAM
|
if( ! gfEnsureBlock() )goto eof_or_fail; // fetch it into RAM
|
||||||
rdPtr = start = blockBuffBegin;
|
rdPtr = start = blockBuffBegin;
|
||||||
} else {
|
} else {
|
||||||
if(++consecutiveCommentLines == 255){
|
if(consecutiveCommentLines >= 250){
|
||||||
|
// SERIAL_ECHO("ccl=");
|
||||||
|
// SERIAL_ECHOLN((int)consecutiveCommentLines);
|
||||||
// SERIAL_PROTOCOLLN(sd->curPosition_);
|
// SERIAL_PROTOCOLLN(sd->curPosition_);
|
||||||
--rdPtr; // unget the already consumed newline
|
--rdPtr; // unget the already consumed newline
|
||||||
goto emit_char;
|
goto emit_char;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue