Tmux: terminfo suggested in FAQ causes SIGSEGV in tic

Created on 15 Nov 2015  Â·  5Comments  Â·  Source: tmux/tmux

If I copy the code below in to a file, say tmux+tmux-256color.terminfo, then tic -x tmux+tmux-256color.terminfo crashes:

tmux|tmux terminal multiplexer,
    ritm=\E[23m, rmso=\E[27m, sitm=\E[3m, smso=\E[7m, Ms@,
    use=xterm+tmux, use=screen,

tmux-256color|tmux with 256 colors,
    use=xterm+256setaf, use=tmux,

The exact error from running tic -x tmux+tmux-256color.terminfo in a fish shell is:

'tic -x tmux+tmux-256color.termi…' terminated by signal SIGSEGV (Address boundary error)

I get Segmentation fault: 11 when the command is run from bash. I am running OS X 10.11.1, with tmux 2.1 installed via Homebrew.

The same crash occurs if I split the two terminfos up in to multiple files, say tmux.terminfo and tmux-256color.terminfo.

I can get the tic command to work if I delete Ms@, from the tmux definition and +256setaf from the tmux-256color definition, but I think this changes the functionality.

Most helpful comment

It is usually part of ncurses. Or just use this one:

#   Reconstructed via infocmp from file: /usr/share/misc/terminfo
tmux-256color|tmux with 256 colors,
    OTbs, OTpt, am, ccc@, hs, km, mir, msgr, xenl, AX, G0,
    colors#256, cols#80, it#8, lines#24, ncv@, pairs#32767, U8#1,
    acsc=++\,\,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
    bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
    clear=\E[H\E[J, cnorm=\E[34h\E[?25h, cr=^M,
    csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H,
    cud=\E[%p1%dB, cud1=^J, cuf=\E[%p1%dC, cuf1=\E[C,
    cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\EM,
    cvvis=\E[34l, dch=\E[%p1%dP, dch1=\E[P, dim=\E[2m,
    dl=\E[%p1%dM, dl1=\E[M, dsl=\E]0;\007, ed=\E[J, el=\E[K,
    el1=\E[1K, enacs=\E(B\E)0, flash=\Eg, fsl=^G, home=\E[H,
    ht=^I, hts=\EH, ich=\E[%p1%d@, il=\E[%p1%dL, il1=\E[L,
    ind=^J, initc@, is2=\E)0, kbs=\177, kcbt=\E[Z, kcub1=\EOD,
    kcud1=\EOB, kcuf1=\EOC, kcuu1=\EOA, kdch1=\E[3~,
    kend=\E[4~, kf1=\EOP, kf10=\E[21~, kf11=\E[23~,
    kf12=\E[24~, kf2=\EOQ, kf3=\EOR, kf4=\EOS, kf5=\E[15~,
    kf6=\E[17~, kf7=\E[18~, kf8=\E[19~, kf9=\E[20~,
    khome=\E[1~, kich1=\E[2~, kmous=\E[M, knp=\E[6~, kpp=\E[5~,
    nel=\EE, op=\E[39;49m, rc=\E8, rev=\E[7m, ri=\EM,
    ritm=\E[23m, rmacs=^O, rmcup=\E[?1049l, rmir=\E[4l,
    rmkx=\E[?1l\E>, rmso=\E[27m, rmul=\E[24m,
    rs2=\Ec\E[?1000l\E[?25h, sc=\E7,
    setab=\E[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m,
    setaf=\E[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m,
    setb@, setf@,
    sgr=\E[0%?%p6%t;1%;%?%p1%t;3%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p5%t;2%;m%?%p9%t\016%e\017%;,
    sgr0=\E[m\017, sitm=\E[3m, smacs=^N, smcup=\E[?1049h,
    smir=\E[4h, smkx=\E[?1h\E=, smso=\E[7m, smul=\E[4m,
    tbc=\E[3g, tsl=\E]0;, Cr=\E]112\007, Cs=\E]12;%p1%s\007,
    E0=\E(B, Ms@, S0=\E(%p1%c, Se=\E[2 q, Ss=\E[%p1%d q,
    TS=\E]0;,

All 5 comments

I expect your terminfo is too old and doesn't have the bits these entries need either.

The only other machine I have access to right now runs Scientific Linux 6, and there I get:

"tmux.terminfo", line 3, terminal 'tmux': resolution of use=xterm+tmux failed

which certainly sounds like something else is missing on my local (OS X) install.

Do you have an idea how I could ‘update’ my terminfo database? I can't see anything super obvious after a quick Google.

It is usually part of ncurses. Or just use this one:

#   Reconstructed via infocmp from file: /usr/share/misc/terminfo
tmux-256color|tmux with 256 colors,
    OTbs, OTpt, am, ccc@, hs, km, mir, msgr, xenl, AX, G0,
    colors#256, cols#80, it#8, lines#24, ncv@, pairs#32767, U8#1,
    acsc=++\,\,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
    bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
    clear=\E[H\E[J, cnorm=\E[34h\E[?25h, cr=^M,
    csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H,
    cud=\E[%p1%dB, cud1=^J, cuf=\E[%p1%dC, cuf1=\E[C,
    cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\EM,
    cvvis=\E[34l, dch=\E[%p1%dP, dch1=\E[P, dim=\E[2m,
    dl=\E[%p1%dM, dl1=\E[M, dsl=\E]0;\007, ed=\E[J, el=\E[K,
    el1=\E[1K, enacs=\E(B\E)0, flash=\Eg, fsl=^G, home=\E[H,
    ht=^I, hts=\EH, ich=\E[%p1%d@, il=\E[%p1%dL, il1=\E[L,
    ind=^J, initc@, is2=\E)0, kbs=\177, kcbt=\E[Z, kcub1=\EOD,
    kcud1=\EOB, kcuf1=\EOC, kcuu1=\EOA, kdch1=\E[3~,
    kend=\E[4~, kf1=\EOP, kf10=\E[21~, kf11=\E[23~,
    kf12=\E[24~, kf2=\EOQ, kf3=\EOR, kf4=\EOS, kf5=\E[15~,
    kf6=\E[17~, kf7=\E[18~, kf8=\E[19~, kf9=\E[20~,
    khome=\E[1~, kich1=\E[2~, kmous=\E[M, knp=\E[6~, kpp=\E[5~,
    nel=\EE, op=\E[39;49m, rc=\E8, rev=\E[7m, ri=\EM,
    ritm=\E[23m, rmacs=^O, rmcup=\E[?1049l, rmir=\E[4l,
    rmkx=\E[?1l\E>, rmso=\E[27m, rmul=\E[24m,
    rs2=\Ec\E[?1000l\E[?25h, sc=\E7,
    setab=\E[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m,
    setaf=\E[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m,
    setb@, setf@,
    sgr=\E[0%?%p6%t;1%;%?%p1%t;3%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p5%t;2%;m%?%p9%t\016%e\017%;,
    sgr0=\E[m\017, sitm=\E[3m, smacs=^N, smcup=\E[?1049h,
    smir=\E[4h, smkx=\E[?1h\E=, smso=\E[7m, smul=\E[4m,
    tbc=\E[3g, tsl=\E]0;, Cr=\E]112\007, Cs=\E]12;%p1%s\007,
    E0=\E(B, Ms@, S0=\E(%p1%c, Se=\E[2 q, Ss=\E[%p1%d q,
    TS=\E]0;,

Installing this term type works fine. I can't say I fully understand what's missing on my OS X install, but OK, it's a mystery I'm willing to live with.

Thank you!

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dragonxlwang picture dragonxlwang  Â·  5Comments

mhartington picture mhartington  Â·  3Comments

pvltlnv picture pvltlnv  Â·  5Comments

Ovid picture Ovid  Â·  4Comments

sc0ty picture sc0ty  Â·  4Comments