circo

claudio's IRC oasis
git clone git://git.bitsmanent.org/circo
Log | Files | Refs | README | LICENSE

commit 5e2022ff5af70b95a8d410a3f981bb22b7cca86a
parent 2a835601eeb755d8976b7d4cd8f8a39e934f5d20
Author: Claudio Alessi <smoppy@gmail.com>
Date:   Sat,  8 Jul 2017 23:20:19 +0200

Fix cols limit in drawbuf().

Diffstat:
Mcirco.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/circo.c b/circo.c @@ -218,8 +218,8 @@ drawbuf(void) { } else { y -= txt.len / cols; - for(j = 0; j < txt.len && i > 1; ++j) { - if(x >= cols - 1) { + for(j = 0; j < txt.len && y > 1; ++j) { + if(x > cols) { ++y; x = 1; } @@ -431,7 +431,7 @@ parsesrv(void) { } else if(!strcmp("JOIN", cmd)) { if(strcmp(usr, nick)) { - printb(getbuf(par), "JOIN %s (%s)", usr, txt); + printb(getbuf(par), "JOIN %s", usr); return; } printb((sel = newbuf(par)), "You joined %s", par);