Correct treatment of erase character with repeat

This commit is contained in:
Keith Winstein
2011-08-14 02:02:24 -04:00
parent 549a3c3393
commit dbdd0d33cd
+1 -1
View File
@@ -434,7 +434,7 @@ static Function func_CSI_HPA( CSI, "\x60", CSI_HPA ); /* ECMA-48 name: HPA */
void CSI_ECH( Framebuffer *fb, Dispatcher *dispatch )
{
int num = dispatch->getparam( 0, 1 );
int limit = fb->ds.get_cursor_col() + num;
int limit = fb->ds.get_cursor_col() + num - 1;
if ( limit >= fb->ds.get_width() ) {
limit = fb->ds.get_width() - 1;
}