X-Git-Url: https://git.armaanb.net/?a=blobdiff_plain;f=st.c;h=48d65cab6c173afb2f5e14b3badf5b1836182576;hb=b650256044f867851725f712fdac58d4ff294808;hp=c383b43052a3815ecc99600b29098117ccc12d3e;hpb=add0211522737b79dad990ccd65c8af63b5cc1dd;p=st.git diff --git a/st.c b/st.c index c383b43..48d65ca 100644 --- a/st.c +++ b/st.c @@ -1830,7 +1830,7 @@ csireset(void) void strhandle(void) { - char *p = NULL; + char *p = NULL, *dec; int j, narg, par; term.esc &= ~(ESC_STR_END|ESC_STR); @@ -1848,8 +1848,6 @@ strhandle(void) return; case 52: if (narg > 2) { - char *dec; - dec = base64dec(strescseq.args[2]); if (dec) { xsetsel(dec); @@ -1867,7 +1865,10 @@ strhandle(void) case 104: /* color reset, here p = NULL */ j = (narg > 1) ? atoi(strescseq.args[1]) : -1; if (xsetcolorname(j, p)) { - fprintf(stderr, "erresc: invalid color %s\n", p); + if (par == 104 && narg <= 1) + return; /* color reset without parameter */ + fprintf(stderr, "erresc: invalid color j=%d, p=%s\n", + j, p ? p : "(null)"); } else { /* * TODO if defaultbg color is changed, borders