Crash on multiple encoding changes
Change the encoding to some non-UTF-8, then back to UTF-8, then again to something else.
VTE crashes with free(): invalid pointer
#0 0x00007fcb1571ce97 in __GI_raise (sig=sig@entry=6)
at ../sysdeps/unix/sysv/linux/raise.c:51
#1 0x00007fcb1571e801 in __GI_abort () at abort.c:79
#2 0x00007fcb15767897 in __libc_message (action=action@entry=do_abort, fmt=fmt@entry=0x7fcb15894b9a "%s\n") at ../sysdeps/posix/libc_fatal.c:181
#3 0x00007fcb1576e90a in malloc_printerr (str=str@entry=0x7fcb15892d88 "free(): invalid pointer") at malloc.c:5350
#4 0x00007fcb15775e1c in _int_free (have_lock=0, p=0x7fcb16209330, av=0x7fcb15ac9c40 <main_arena>) at malloc.c:4157
#5 0x00007fcb15775e1c in __GI___libc_free (mem=0x7fcb16209340 <g_timeout_funcs>) at malloc.c:3124
#6 0x00007fcb15700cf1 in __gconv_close (cd=0x5568c41d9890) at gconv_close.c:40
#7 0x00007fcb1570054f in iconv_close (cd=<optimized out>) at iconv_close.c:35
#8 0x00007fcb17a9722b in vte::terminal::Terminal::pty_termios_changed() (this=0x2) at vte.cc:3171
#9 0x00005568c3fc5270 in ()
#10 0x48c6edf6fa69cd00 in ()
#11 0x00005568c4045a60 in ()
#12 0x00005568c3fc5270 in ()
#13 0x0000000000000000 in ()