Fix Terminal BasicTerminalBuffer::_InsertGap() to not set length longer than allocated space
|Reported by:||joshe||Owned by:||stippi|
|Has a Patch:||no||Platform:||All|
_InsertGap() unconditionally adds the width of the gap to the line width, even though the actual memmove() takes into account that the gap might be too large for the line buffer. Attached is a patch which insures that the line length won't be expanded beyond the size of the buffer, which is equal to the screen width.