Introduction
Introduction Statistics Contact Development Disclaimer Help
tdump escseq if not handled. - st - [fork] customized build of st, the simple t…
git clone git://src.adamsgaard.dk/st
Log
Files
Refs
README
LICENSE
---
commit d5f4554431f82424af40600ed6835672ab8e44ae
parent 53937e045aba6cdefd9e8e81556b306976691747
Author: AurĂ©lien Aptel <[email protected]>
Date: Tue, 16 Jun 2009 12:34:10 +0200
dump escseq if not handled.
Diffstat:
M st.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
---
diff --git a/st.c b/st.c
t@@ -591,10 +591,16 @@ tsetscroll(int t, int b) {
void
eschandle(void) {
- /* escdump(); */
switch(escseq.pre) {
+ default:
+ goto unknown_seq;
case '[':
switch(escseq.mode) {
+ default:
+ unknown_seq:
+ fprintf(stderr, "erresc: unknown sequence\n");
+ escdump();
+ break;
case '@': /* Insert <n> blank char */
DEFAULT(escseq.arg[0], 1);
tinsertblank(escseq.arg[0]);
t@@ -712,15 +718,13 @@ eschandle(void) {
void
escdump(void) {
int i;
- puts("------");
printf("rawbuf : %s\n", escseq.buf);
printf("prechar : %c\n", escseq.pre);
printf("private : %c\n", escseq.priv ? '?' : ' ');
printf("narg : %d\n", escseq.narg);
- if(escseq.narg) {
+ if(escseq.narg)
for(i = 0; i < escseq.narg; i++)
printf("\targ %d = %d\n", i, escseq.arg[i]);
- }
printf("mode : %c\n", escseq.mode);
}
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.