From: pk910 Date: Wed, 10 Aug 2011 00:55:58 +0000 (+0200) Subject: tried to fix parse_lines #4 X-Git-Tag: v5.3~632 X-Git-Url: http://git.pk910.de/?a=commitdiff_plain;h=2723638b80cfdbad9cdc522f18deeba0af691190;p=NeonServV5.git tried to fix parse_lines #4 --- diff --git a/IRCParser.c b/IRCParser.c index 899a10e..40edec9 100644 --- a/IRCParser.c +++ b/IRCParser.c @@ -16,10 +16,9 @@ int parse_lines(struct ClientSocket *client, char *lines, int len) { lines[i] = 0; if(lines[i] == '\n') { lines[i] = 0; - startpos = strlen(lines); //save length of the current line parse_line(client, lines); - lines += startpos+1; - printf("SKIP %d: %s\n", startpos+1, lines); + lines += i-startpos+1; + printf("SKIP %d: %s\n", i-startpos+1, lines); startpos = i+1; } }