From deb741585f4132fc24b49cded95b03617919e5e4 Mon Sep 17 00:00:00 2001 From: Ali Gholami Rudi Date: Tue, 20 Oct 2009 20:12:26 +0330 Subject: [PATCH] some random style fixes --- draw.c | 4 ++-- term.c | 4 ++-- vt102.c | 22 +++++++++++----------- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/draw.c b/draw.c index 3666fa3..65e96e9 100644 --- a/draw.c +++ b/draw.c @@ -21,7 +21,7 @@ static struct fb_fix_screeninfo finfo; static int rl, rr, gl, gr, bl, br; static int nr, ng, nb; -static int fb_len() +static int fb_len(void) { return vinfo.xres_virtual * vinfo.yres_virtual * BPP; } @@ -118,7 +118,7 @@ void fb_set(int r, int c, fbval_t *mem, int len) memcpy(fb + loc, mem, len * BPP); } -void fb_free() +void fb_free(void) { fb_cmap_save(0); munmap(fb, fb_len()); diff --git a/term.c b/term.c index 643502e..4a525ff 100644 --- a/term.c +++ b/term.c @@ -126,13 +126,13 @@ static void lazy_cursor(int put) _term_show(row, col, put); } -static void lazy_clean() +static void lazy_clean(void) { if (visible) memset(dirty, 0, sizeof(*dirty) * MAXLINES); } -static void lazy_flush() +static void lazy_flush(void) { int i; if (!visible) diff --git a/vt102.c b/vt102.c index d49c8a1..4a538ab 100644 --- a/vt102.c +++ b/vt102.c @@ -83,7 +83,7 @@ static void escseq(void) int c = readpty(); while (ESCM(c)) c = readpty(); - switch(c) { + switch (c) { case '[': /* CSI control sequence introducer */ csiseq(); break; @@ -148,7 +148,7 @@ static void escseq(void) static void escseq_cs(void) { int c = readpty(); - switch(c) { + switch (c) { case '@': /* CSDFL select default charset (ISO646/8859-1) */ case 'G': /* CSUTF8 select UTF-8 */ case '8': /* CSUTF8 select UTF-8 (obsolete) */ @@ -161,7 +161,7 @@ static void escseq_cs(void) static void escseq_g0(void) { int c = readpty(); - switch(c) { + switch (c) { case '8': /* G0DFL G0 charset = default mapping (ISO8859-1) */ case '0': /* G0GFX G0 charset = VT100 graphics mapping */ case 'U': /* G0ROM G0 charset = null mapping (straight to ROM) */ @@ -176,7 +176,7 @@ static void escseq_g0(void) static void escseq_g1(void) { int c = readpty(); - switch(c) { + switch (c) { case '8': /* G1DFL G1 charset = default mapping (ISO8859-1) */ case '0': /* G1GFX G1 charset = VT100 graphics mapping */ case 'U': /* G1ROM G1 charset = null mapping (straight to ROM) */ @@ -191,7 +191,7 @@ static void escseq_g1(void) static void escseq_g2(void) { int c = readpty(); - switch(c) { + switch (c) { case '8': /* G2DFL G2 charset = default mapping (ISO8859-1) */ case '0': /* G2GFX G2 charset = VT100 graphics mapping */ case 'U': /* G2ROM G2 charset = null mapping (straight to ROM) */ @@ -205,7 +205,7 @@ static void escseq_g2(void) static void escseq_g3(void) { int c = readpty(); - switch(c) { + switch (c) { case '8': /* G3DFL G3 charset = default mapping (ISO8859-1) */ case '0': /* G3GFX G3 charset = VT100 graphics mapping */ case 'U': /* G3ROM G3 charset = null mapping (straight to ROM) */ @@ -255,13 +255,13 @@ static void csiseq(void) inter = c; c = readpty(); } - switch(c) { + switch (c) { case 'H': /* CUP move cursor to row, column */ case 'f': /* HVP move cursor to row, column */ move_cursor(absrow(MAX(0, args[0] - 1)), MAX(0, args[1] - 1)); break; case 'J': /* ED erase display */ - switch(args[0]) { + switch (args[0]) { case 0: kill_chars(col, pad_cols()); blank_rows(row + 1, pad_rows()); @@ -365,7 +365,7 @@ static void csiseq(void) static void csiseq_da(int c) { - switch(c) { + switch (c) { case 0x00: term_sendstr("\x1b[?6c"); break; @@ -379,7 +379,7 @@ static void csiseq_da(int c) static void csiseq_dsr(int c) { char status[1 << 5]; - switch(c) { + switch (c) { case 0x05: term_sendstr("\x1b[0n"); break; @@ -397,7 +397,7 @@ static void csiseq_dsr(int c) /* ANSI/DEC specified modes for SM/RM ANSI Specified Modes */ static void modeseq(int c, int set) { - switch(c) { + switch (c) { case 0x87: /* DECAWM Auto Wrap */ mode = BIT_SET(mode, MODE_WRAP, set); break; -- 2.11.4.GIT