Download raw body.
Adding ECMA-48 REP to wscons to fix breakage
Hi Stuart, On Sun, Jul 07, 2024 at 09:22:12PM +0100, Stuart Henderson wrote: > On 2024/06/20 06:35, Crystal Kolipe wrote: > > +edp->last_printed_char=instate->inchar; > > ^ whitespace, missing tab Fixed, along with other style(9) changes pointed out off-list. New version attached, no functional change. --- sys/dev/wscons/wsemul_vt100.c Wed Aug 2 20:20:19 2023 +++ sys/dev/wscons/wsemul_vt100.c Mon Jul 8 12:52:07 2024 @@ -394,6 +394,8 @@ } } + edp->last_printed_char = instate->inchar; + #ifdef HAVE_DOUBLE_WIDTH_HEIGHT WSEMULOP(rc, edp, &edp->abortstate, putchar, (edp->emulcookie, edp->crow, edp->ccol << edp->dw, dc, --- sys/dev/wscons/wsemul_vt100_subr.c Sun Feb 26 15:09:53 2023 +++ sys/dev/wscons/wsemul_vt100_subr.c Mon Jul 8 12:47:28 2024 @@ -43,7 +43,8 @@ #define VTMODE_SET 33 #define VTMODE_RESET 44 #define VTMODE_REPORT 55 - +extern int wsemul_vt100_output_normal(struct wsemul_vt100_emuldata *edp, + struct wsemul_inputstate *instate, int kernel); /* * scroll up within scrolling region */ @@ -548,6 +549,16 @@ break; } break; + case 'b': /* REP - repeat previously printed character */ + instate->inchar = edp->last_printed_char; + /* + * We arbitrarily limit the repeat count to 65535 to avoid + * un-interruptable flooding of the console. This matches + * current xterm behaviour. + */ + for (m = 0; m < (DEF1_ARG(0) < 65535 ? DEF1_ARG(0) : 65535); m++) + wsemul_vt100_output_normal(edp, instate, 0); + break; case 'c': /* DA primary */ if (ARG(0) == 0) wsdisplay_emulinput(edp->cbcookie, WSEMUL_VT_ID1, --- sys/dev/wscons/wsemul_vt100var.h Mon Mar 6 17:14:44 2023 +++ sys/dev/wscons/wsemul_vt100var.h Mon May 27 16:45:26 2024 @@ -99,6 +99,7 @@ #else u_char translatebuf[1]; #endif + uint32_t last_printed_char; }; /* some useful utility macros */
Adding ECMA-48 REP to wscons to fix breakage