aboutsummaryrefslogtreecommitdiffstats
path: root/kirc.c
diff options
context:
space:
mode:
authormcpcpc <michaelczigler@icloud.com>2020-08-26 08:40:50 -0400
committermcpcpc <michaelczigler@icloud.com>2020-08-26 08:40:50 -0400
commit66fe4973698a91b0532891d83c1541afc4152bac (patch)
treea3e9af0b4538c749118c018c302b16e5a7f4f341 /kirc.c
parentMerge pull request #3 from mcpcpc/ringbuffer (diff)
downloadkirc-66fe4973698a91b0532891d83c1541afc4152bac.tar.gz
kirc-66fe4973698a91b0532891d83c1541afc4152bac.tar.bz2
kirc-66fe4973698a91b0532891d83c1541afc4152bac.tar.xz
kirc-66fe4973698a91b0532891d83c1541afc4152bac.tar.zst
kirc-66fe4973698a91b0532891d83c1541afc4152bac.zip
remove tab chars
Diffstat (limited to 'kirc.c')
-rw-r--r--kirc.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/kirc.c b/kirc.c
index d550c2f..5d500db 100644
--- a/kirc.c
+++ b/kirc.c
@@ -217,12 +217,13 @@ main(int argc, char **argv) {
while ((sl = read(conn, &s, 1))) {
if (sl > 0) b[o] = s;
- if ((o > 0 && b[o - 1] == '\r' && b[o] == '\n') || o == IRC_MSG_MAX) {
+
+ if ((o > 0 && b[o - 1] == '\r' && b[o] == '\n') || o == IRC_MSG_MAX) {
b[o + 1] = '\0';
- parser(b);
- o = 0;
+ parser(b);
+ o = 0;
}
- else if (sl > 0) o++;
+ else if (sl > 0) o++;
if (read(fd[0], u, IRC_MSG_MAX) > 0) {
for (i = 0; u[i] != '\n'; i++) continue;
if (u[0] != ':') raw("%-*.*s\r\n", i, i, u);