Download raw body.
XTerm segfault
On Sun, Aug 11, 2024 at 05:20:42PM -0500, Matthew Martin wrote:
> On OpenBSD-current with XTerm patch 393, running
> printf '\e[3m\xe2\x80\x99'
> causes xterm to segfault. The cause seems to be in xtermFullString16 in
> util.c with the expansion of XTermFontsRef; namely xf - fn is out of
> range of TScreen.fnts. The below patch appears to fix the issue.
thanks (the fix looks right...)
> diff --git a/util.c b/util.c
> index 06de3e64f..de73d112c 100644
> --- a/util.c
> +++ b/util.c
> @@ -3901,7 +3901,7 @@ xtermFullString16(XTermDraw * params, unsigned flags, GC gc,
> (ch > NARROW_ICHAR) ||
> #endif
> xtermMissingChar(ch,
> - (((xf >= fn) && (xf - fn) <= fMAX)
> + (((xf >= fn) && (xf - fn) < fMAX)
> ? XTermFontsRef(screen->fnts,
> (VTFontEnum) (xf - fn))
> : fp))) {
>
--
Thomas E. Dickey <dickey@invisible-island.net>
https://invisible-island.net
XTerm segfault