Re: [dev] [st patch queue 06/12] Avoid integer overflow in dump().

2014-04-25 Thread Roberto E. Vargas Caballero
> @@ -1234,8 +1234,10 @@ dump(char c) { > static int col; > > fprintf(stderr, " %02x '%c' ", c, isprint(c)?c:'.'); > - if(++col % 10 == 0) > + if(++col == 10) { > fprintf(stderr, "\n"); > + col = 0; > + } > } dump is not used in any place. It is

[dev] [st patch queue 06/12] Avoid integer overflow in dump().

2014-04-25 Thread noname
--- st.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/st.c b/st.c index dae23c5..9de7f81 100644 --- a/st.c +++ b/st.c @@ -1234,8 +1234,10 @@ dump(char c) { static int col; fprintf(stderr, " %02x '%c' ", c, isprint(c)?c:'.'); - if(++col % 10 == 0) +