Commit 645b92a5 authored by Waqar Ahmed's avatar Waqar Ahmed Committed by Tomaz Canabrava
Browse files

Fix possible infinite loop

parent fd689b3a
Pipeline #99879 passed with stage
in 1 minute and 51 seconds
......@@ -147,6 +147,9 @@ void TerminalPainter::drawContents(Character *image,
if (next_char.character == ' ' && char_value.hasSameColors(next_char) && char_value.hasSameRendition(next_char)) {
// univec intentionally not modified - trailing spaces are meaningless
len++;
} else {
// break otherwise, we don't want to be stuck in this loop
break;
}
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment